/* Love Cat Studio — the handful of styles Tailwind utilities do not cover.
   Everything else lives in class names on the markup. */

:root {
    --brand-text: #1a1a1a;
    --brand-muted: #737373;
    --brand-border: #e5e5e5;
    --brand-surface: #f5f3f0;
}

html {
    scroll-behavior: smooth;
}

body {
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

/* Keyboard-only escape hatch past the navigation. */
.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 100;
    background: var(--brand-text);
    color: #fff;
    padding: 0.75rem 1.25rem;
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.skip-link:focus {
    left: 0;
}

/* Current-section marker, set from the body[data-page] attribute. */
.site-nav a[aria-current='page'] {
    color: var(--brand-text);
    border-bottom: 1px solid var(--brand-text);
    padding-bottom: 2px;
}

/* Content injected from the CMS fades in once it has been rendered. */
[data-cms] {
    opacity: 0;
    transition: opacity 0.5s ease-out;
}

[data-cms].is-ready {
    opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    [data-cms],
    [data-cms].is-ready {
        opacity: 1;
        transition: none;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* Long-form article and page copy rendered from Markdown. */
.prose-editorial {
    font-weight: 300;
    line-height: 1.85;
    color: #333;
}

.prose-editorial > * + * {
    margin-top: 1.5rem;
}

.prose-editorial p {
    font-size: 1.0625rem;
}

.prose-editorial h2,
.prose-editorial h3,
.prose-editorial h4 {
    font-family: 'Playfair Display', serif;
    font-weight: 400;
    color: var(--brand-text);
    line-height: 1.3;
    margin-top: 3rem;
}

.prose-editorial h2 { font-size: 2rem; }
.prose-editorial h3 { font-size: 1.5rem; }
.prose-editorial h4 { font-size: 1.25rem; }

.prose-editorial a {
    color: var(--brand-text);
    border-bottom: 1px solid var(--brand-border);
    transition: border-color 0.3s ease;
}

.prose-editorial a:hover {
    border-color: var(--brand-text);
}

.prose-editorial ul,
.prose-editorial ol {
    padding-left: 1.25rem;
}

.prose-editorial ul { list-style: disc; }
.prose-editorial ol { list-style: decimal; }

.prose-editorial li + li {
    margin-top: 0.5rem;
}

.prose-editorial blockquote {
    border-left: 1px solid var(--brand-text);
    padding-left: 1.75rem;
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-size: 1.375rem;
    line-height: 1.6;
    color: var(--brand-text);
}

.prose-editorial blockquote p {
    font-size: inherit;
}

.prose-editorial img {
    width: 100%;
    height: auto;
    margin: 2.5rem 0;
}

.prose-editorial hr {
    border: 0;
    border-top: 1px solid var(--brand-border);
    margin: 3rem 0;
}

.prose-editorial code {
    font-size: 0.9em;
    background: var(--brand-surface);
    padding: 0.15em 0.4em;
}

/* Placeholder shown while a JSON content file is still loading. */
.loading-line {
    display: block;
    height: 1rem;
    background: var(--brand-surface);
    animation: pulse 1.4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.45; }
}
