html {
    scroll-behavior: smooth;
}

html:not(.theme-ready) body {
    visibility: hidden;
}

.not-found-pattern {
    background-image: radial-gradient(#cbd5e1 1px, transparent 1px);
    background-size: 40px 40px;
}

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

.editorial-page {
    --editorial-text: #475569;
    --editorial-border: #e2e8f0;
    --editorial-surface: #f8fafc;
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 24px;
}

html[data-theme="night"] .editorial-page {
    --editorial-text: #cbd5e1;
    --editorial-border: #334155;
    --editorial-surface: #0f172a;
}

.editorial-page h1 {
    max-width: 850px;
    margin: 18px 0 24px;
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    line-height: 1.15;
    font-weight: 800;
    letter-spacing: -0.035em;
}

.editorial-page h2 {
    margin: 16px 0;
    font-size: 1.4rem;
    line-height: 1.4;
    font-weight: 700;
}

.editorial-page p,
.editorial-page li {
    color: var(--editorial-text);
    line-height: 1.85;
}

.editorial-page .editorial-eyebrow {
    color: #0891b2;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.editorial-intro {
    max-width: 760px;
    font-size: 1.15rem;
}

.resource-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    margin-top: 48px;
}

.resource-card,
.editorial-callout {
    border: 1px solid var(--editorial-border);
    border-radius: 16px;
    padding: 28px;
    background: var(--editorial-surface);
}

.resource-link {
    display: inline-block;
    margin-top: 16px;
    color: #0891b2;
    font-weight: 600;
}

.resource-link:hover {
    text-decoration: underline;
}

.resource-button {
    display: inline-block;
    margin-top: 24px;
    padding: 14px 24px;
    border-radius: 12px;
    background: #0891b2;
    color: #fff;
    font-weight: 700;
}

.resource-button:hover {
    background: #0e7490;
}

.editorial-article {
    max-width: 900px;
}

.editorial-article > section,
.editorial-callout {
    margin-top: 40px;
}

.editorial-article ul {
    list-style: disc;
    padding-left: 24px;
}

.editorial-article li + li {
    margin-top: 10px;
}

@media (max-width: 800px) {
    .editorial-page {
        padding-top: 48px;
        padding-bottom: 48px;
    }

    .resource-grid {
        grid-template-columns: 1fr;
    }
}

.hero-portrait {
    overflow: hidden;
    border-radius: 24px;
    border: 1px solid rgba(8, 145, 178, 0.18);
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.16);
}

.hero-portrait img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 1;
    object-fit: cover;
    object-position: 30% center;
}

.contact-email {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    margin: 2rem 0;
    padding: 1.5rem;
    border: 1px solid var(--editorial-border);
    border-radius: 1rem;
    background: var(--editorial-surface);
}

.contact-email .editorial-eyebrow {
    margin: 0;
}

.contact-email__address {
    font-size: 1.5rem;
    font-weight: 700;
    color: #0e7490;
    word-break: break-all;
}

html[data-theme="night"] .contact-email__address {
    color: #67e8f9;
}

.contact-email__address:hover {
    text-decoration: underline;
}

.resource-card h3 {
    margin: 0.25rem 0 0.5rem;
    font-size: 1.05rem;
    font-weight: 700;
}

.jobs-page {
    --jobs-input-bg: #ffffff;
    --jobs-badge-bg: #ecfeff;
    --jobs-badge-text: #155e75;
    --jobs-salary: #15803d;
    --jobs-heading: #0f172a;
}

html[data-theme="night"] .jobs-page {
    --jobs-input-bg: #0b1220;
    --jobs-badge-bg: rgba(8, 145, 178, 0.18);
    --jobs-badge-text: #a5f3fc;
    --jobs-salary: #4ade80;
    --jobs-heading: #f8fafc;
}

.jobs-layout {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 32px;
    margin-top: 40px;
    align-items: start;
}

.jobs-layout__filters {
    position: sticky;
    top: 96px;
}

.jobs-filters {
    border: 1px solid var(--editorial-border);
    border-radius: 16px;
    padding: 24px;
    background: var(--editorial-surface);
}

.editorial-page .jobs-filters__title {
    margin: 0 0 16px;
    font-size: 1.05rem;
}

.jobs-field {
    margin-bottom: 14px;
}

.jobs-field label {
    display: block;
    margin-bottom: 6px;
    color: var(--jobs-heading);
    font-size: 0.85rem;
    font-weight: 600;
}

.jobs-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--editorial-border);
    border-radius: 10px;
    background: var(--jobs-input-bg);
    color: var(--jobs-heading);
    font-size: 0.9rem;
}

.jobs-input:focus {
    outline: 2px solid #0891b2;
    outline-offset: 1px;
}

.jobs-filters__actions {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}

.jobs-filters__submit {
    width: 100%;
    margin-top: 8px;
    border: none;
    cursor: pointer;
    text-align: center;
}

.editorial-page .jobs-count {
    margin: 0 0 16px;
}

.editorial-page .jobs-count strong {
    color: var(--jobs-heading);
}

.job-card {
    display: flex;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 16px;
    padding: 24px;
    border: 1px solid var(--editorial-border);
    border-radius: 16px;
    background: var(--editorial-surface);
}

.job-card:hover {
    border-color: #0891b2;
}

.editorial-page .job-card__title {
    margin: 0 0 6px;
    font-size: 1.15rem;
    line-height: 1.35;
}

.job-card__title a {
    color: var(--jobs-heading);
}

.job-card__title a:hover {
    color: #0891b2;
}

.editorial-page .job-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0 0 12px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.job-card__badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.job-badge {
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--jobs-badge-bg);
    color: var(--jobs-badge-text);
    font-size: 0.8rem;
    font-weight: 600;
}

.job-badge--highlight {
    background: rgba(22, 163, 74, 0.14);
    color: var(--jobs-salary);
}

.job-card__side {
    flex: 0 0 auto;
    text-align: right;
}

.editorial-page .job-salary {
    margin: 0 0 4px;
    color: var(--jobs-salary);
    font-weight: 700;
    line-height: 1.4;
}

.editorial-page .job-card__posted {
    margin: 0;
    font-size: 0.85rem;
}

.job-card__side .resource-link {
    margin-top: 8px;
}

.jobs-inline-callout {
    margin: 8px 0 24px;
}

.jobs-pager {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 24px;
    color: var(--editorial-text);
}

.jobs-pager .resource-link {
    margin-top: 0;
}

.jobs-back {
    margin-top: 0;
}

.job-detail {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 40px;
    margin-top: 24px;
    align-items: start;
}

.editorial-page .job-detail__title {
    margin: 8px 0 12px;
    font-size: clamp(1.75rem, 3.4vw, 2.5rem);
}

.job-facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 32px 0 0;
}

.job-facts__item {
    padding: 16px;
    border: 1px solid var(--editorial-border);
    border-radius: 12px;
    background: var(--editorial-surface);
}

.job-facts__item dt {
    color: var(--editorial-text);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.job-facts__item dd {
    margin: 4px 0 0;
    color: var(--jobs-heading);
    font-weight: 700;
}

.job-teaser {
    margin-top: 40px;
}

.editorial-page .job-teaser__text {
    position: relative;
    margin: 0;
}

.job-gate .job-gate__signin {
    margin: 12px 0 0;
}

.job-gate__signin .resource-link {
    margin-top: 0;
}

.job-detail__side {
    position: sticky;
    top: 96px;
}

.editorial-page .job-side__label {
    margin: 0;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.editorial-page .job-side__salary {
    margin-bottom: 20px;
    font-size: 1.3rem;
}

.job-side__button {
    width: 100%;
    text-align: center;
}

@media (max-width: 960px) {
    .jobs-layout,
    .job-detail {
        grid-template-columns: minmax(0, 1fr);
    }

    .jobs-layout__filters,
    .job-detail__side {
        position: static;
    }
}

@media (max-width: 640px) {
    .job-card {
        flex-direction: column;
        gap: 12px;
    }

    .job-card__side {
        text-align: left;
    }

    .job-facts {
        grid-template-columns: minmax(0, 1fr);
    }
}
