* { box-sizing: border-box; }
html { font-size: 16px; }
body {
    margin: 0;
    font-family: 'Source Sans 3', sans-serif;
    color: #243244;
    background:
        radial-gradient(circle at top, rgba(70, 115, 188, 0.10), transparent 26%),
        linear-gradient(180deg, #eef3f8 0%, #f8fafc 42%, #eef2f6 100%);
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 {
    margin: 0;
    font-family: 'Cormorant Garamond', serif;
    color: #081632;
    line-height: 1.02;
}
p, ul, ol { margin: 0; }
ul, ol { padding-left: 1.25rem; }
li + li { margin-top: 0.55rem; }

.container {
    width: min(1220px, calc(100% - 48px));
    margin: 0 auto;
}
.container.narrow { width: min(860px, calc(100% - 48px)); }
.container.wide { width: min(1340px, calc(100% - 56px)); }

.site-main { padding-top: 94px; }

.site-header {
    position: fixed;
    inset: 0 0 auto;
    z-index: 100;
    background: #040231;
    box-shadow: 0 12px 36px rgba(3, 6, 30, 0.22);
}
.site-header.is-scrolled { box-shadow: 0 18px 42px rgba(2, 4, 24, 0.38); }
.header-inner {
    min-height: 94px;
    display: flex;
    align-items: center;
    gap: 28px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 16px;
    flex: 0 0 auto;
}
.brand-logo {
    width: 72px;
    height: 72px;
    object-fit: contain;
}
.brand-copy {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.brand-copy strong {
    font-size: 1.15rem;
    color: #ffffff;
    letter-spacing: 0.01em;
}
.brand-copy small {
    color: rgba(255, 255, 255, 0.82);
    font-size: 0.84rem;
}

.site-nav { margin-left: auto; }
.site-nav ul {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 30px;
    padding: 0;
    margin: 0;
}
.site-nav li {
    display: flex;
    align-items: center;
    height: 56px;
}
.site-nav a {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 56px;
    padding: 0 2px;
    white-space: nowrap;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.98rem;
    font-weight: 600;
    line-height: 1;
    transition: color 0.22s ease, transform 0.22s ease, opacity 0.22s ease;
    position: relative;
}
.site-nav .nav-label {
    display: block;
    line-height: 1;
    padding-bottom: 0;
}
.site-nav a:hover,
.site-nav a.is-active { color: #9ac6ff; }
.site-nav a.is-active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 6px;
    height: 2px;
    border-radius: 999px;
    background: #9ac6ff;
}

.menu-toggle {
    display: none;
    width: 52px;
    height: 52px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.08);
    padding: 0;
}
.menu-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    margin: 5px auto;
    background: #ffffff;
}

.home-hero,
.page-hero {
    position: relative;
    overflow: hidden;
    background:
        linear-gradient(135deg, rgba(5, 8, 58, 0.84) 0%, rgba(13, 30, 109, 0.80) 48%, rgba(33, 88, 148, 0.68) 100%),
        url('../images/hero-bg.jpg') center/cover no-repeat;
}
.page-hero {
    background:
        linear-gradient(135deg, rgba(5, 8, 58, 0.84) 0%, rgba(13, 30, 109, 0.80) 48%, rgba(33, 88, 148, 0.68) 100%),
        url('../images/about-office.jpg') center/cover no-repeat;
}
.home-hero::before,
.page-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 46px 46px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.45), transparent 82%);
}

.home-hero__inner,
.page-hero .container {
    position: relative;
    z-index: 1;
    padding-top: 88px;
    padding-bottom: 88px;
}
.eyebrow {
    display: inline-flex;
    padding: 8px 14px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.10);
    color: rgba(255, 255, 255, 0.92);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.86rem;
}
.home-hero h1,
.page-hero h1 {
    margin-top: 22px;
    color: #ffffff;
    font-size: clamp(3rem, 7vw, 5.6rem);
}
.page-hero h1 { font-size: clamp(2.8rem, 6vw, 4.5rem); }
.home-hero__subtitle,
.home-hero__intro,
.page-hero p {
    max-width: 820px;
    color: rgba(255, 255, 255, 0.84);
}
.home-hero__subtitle {
    margin-top: 18px;
    font-size: clamp(1.5rem, 2vw, 2rem);
    color: rgba(255, 255, 255, 0.96);
}
.home-hero__intro,
.page-hero p {
    margin-top: 14px;
    font-size: 1.08rem;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 30px;
}
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 54px;
    padding: 0 24px;
    border-radius: 999px;
    border: 1px solid transparent;
    font-weight: 700;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease, background 0.24s ease;
}
.button::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent 0%, rgba(255, 255, 255, 0.18) 48%, transparent 100%);
    transform: translateX(-130%);
    transition: transform 0.55s ease;
}
.button:hover::after {
    transform: translateX(130%);
}
.button:hover {
    transform: translateY(-2px);
}
.button--primary {
    background: linear-gradient(135deg, #2a6cb7 0%, #4f96e1 100%);
    color: #fff;
    box-shadow: 0 16px 36px rgba(43, 105, 178, 0.32);
}
.button--primary:hover {
    box-shadow: 0 22px 40px rgba(43, 105, 178, 0.38);
}
.button--secondary {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.22);
    color: #fff;
}
.button--secondary:hover {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.3);
}

.validation-grid,
.blog-grid,
.two-column-grid,
.services-grid {
    display: grid;
    gap: 24px;
}
.validation-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: 38px;
}
.validation-card,
.content-card,
.blog-card,
.service-card,
.contact-form {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(246, 249, 252, 0.96) 100%);
    border: 1px solid rgba(10, 22, 48, 0.10);
    border-radius: 22px;
    box-shadow: 0 18px 42px rgba(10, 22, 48, 0.08);
    backdrop-filter: blur(8px);
    transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}
.validation-card:hover,
.content-card:hover,
.blog-card:hover,
.service-card:hover,
.contact-form:hover {
    transform: translateY(-4px);
    box-shadow: 0 24px 48px rgba(10, 22, 48, 0.12);
    border-color: rgba(42, 108, 183, 0.18);
}
.validation-card {
    padding: 24px;
}
.validation-card span,
.service-card__number {
    display: inline-flex;
    color: #2b69b2;
    font-size: 0.84rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    margin-bottom: 14px;
}
.validation-card p { font-size: 1rem; line-height: 1.6; }

.page-section { padding: 82px 0; }
.content-card,
.blog-card { padding: 30px; }
.content-card p,
.content-card li,
.blog-card p,
.service-card li,
.article-card p,
.article-card li {
    color: #4c5f72;
    font-size: 1.04rem;
    line-height: 1.74;
}
.content-card p + p,
.content-card ul,
.content-card ol,
.content-card h3,
.article-card h2,
.article-card h3 { margin-top: 1rem; }
.content-card h2,
.blog-card h2,
.service-card h2 {
    margin-bottom: 16px;
    font-size: 2.1rem;
}
.content-card h3 {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 1.1rem;
    color: #0d2750;
}

.services-grid {
    grid-template-columns: repeat(12, minmax(0, 1fr));
}
.service-card {
    grid-column: span 4;
    padding: 32px 28px;
}
.service-card:nth-child(4),
.service-card:nth-child(5) {
    grid-column: span 6;
}

.blog-grid,
.two-column-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.text-link {
    display: inline-flex;
    margin-top: 16px;
    color: #2a6cb7;
    font-weight: 700;
    transition: color 0.2s ease, transform 0.2s ease;
}
.text-link:hover {
    color: #143f74;
    transform: translateX(4px);
}

.contact-form {
    padding: 32px;
}
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}
.form-grid label,
.admin-editor label,
.admin-card label {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.form-grid .full,
.admin-editor .full {
    grid-column: 1 / -1;
}
input, textarea {
    width: 100%;
    border: 1px solid rgba(10, 22, 48, 0.14);
    border-radius: 14px;
    padding: 14px 16px;
    font: inherit;
    color: #243244;
    background: #fcfdff;
}
textarea { resize: vertical; }
.form-success { margin-top: 14px; color: #1d7c47; font-weight: 700; }
.form-error { margin-top: 10px; color: #b42318; font-weight: 700; }

.site-footer {
    background: #040231;
    color: rgba(255, 255, 255, 0.82);
}
.footer-grid {
    display: grid;
    grid-template-columns: 1.3fr 1fr 1fr;
    gap: 28px;
    padding: 52px 0;
}
.footer-links {
    list-style: none;
    padding: 0;
    margin: 16px 0 0;
}
.footer-links li + li { margin-top: 10px; }
.footer-links a:hover { color: #9ac6ff; }

.admin-body {
    background: linear-gradient(180deg, #edf2f8 0%, #f7f9fc 100%);
}
.admin-login,
.admin-main {
    padding: 48px 0 72px;
}
.admin-card,
.admin-section {
    width: min(960px, calc(100% - 48px));
    margin: 0 auto;
    background: #fff;
    border: 1px solid rgba(10, 22, 48, 0.10);
    border-radius: 22px;
    box-shadow: 0 18px 42px rgba(10, 22, 48, 0.08);
}
.admin-card { padding: 32px; max-width: 460px; }
.admin-header {
    background: linear-gradient(90deg, #05083a 0%, #0d1660 48%, #13217d 100%);
    color: #fff;
}
.admin-header__inner {
    min-height: 84px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.admin-header__actions {
    display: flex;
    gap: 12px;
}
.admin-editor {
    display: grid;
    gap: 22px;
}
.admin-section {
    padding: 28px;
}
.admin-subsection + .admin-subsection {
    margin-top: 26px;
    padding-top: 26px;
    border-top: 1px solid rgba(10, 22, 48, 0.08);
}
.admin-savebar {
    width: min(960px, calc(100% - 48px));
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

@media (max-width: 1180px) {
    .services-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .service-card,
    .service-card:nth-child(4),
    .service-card:nth-child(5) { grid-column: span 1; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 980px) {
    .menu-toggle { display: inline-block; }
    .site-nav {
        position: fixed;
        top: 94px;
        left: 20px;
        right: 20px;
        background: rgba(4, 2, 49, 0.98);
        border: 1px solid rgba(255, 255, 255, 0.12);
        border-radius: 20px;
        padding: 22px;
        opacity: 0;
        pointer-events: none;
        transform: translateY(-8px);
        transition: opacity 0.2s ease, transform 0.2s ease;
    }
    .site-nav.is-open {
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }
    .site-nav ul,
    .blog-grid,
    .two-column-grid,
    .validation-grid,
    .form-grid,
    .footer-grid {
        grid-template-columns: 1fr;
    }
    .site-nav ul {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 18px;
    }
}

@media (max-width: 720px) {
    .site-main { padding-top: 82px; }
    .header-inner { min-height: 82px; }
    .brand-logo { width: 58px; height: 58px; }
    .brand-copy small { display: none; }
    .home-hero__inner,
    .page-hero .container,
    .page-section { padding-top: 68px; padding-bottom: 68px; }
    .services-grid { grid-template-columns: 1fr; }
    .service-card,
    .service-card:nth-child(4),
    .service-card:nth-child(5) { grid-column: span 1; }
    .admin-header__inner,
    .admin-savebar { flex-direction: column; align-items: flex-start; }
}
