:root {
    --navy: #162434;
    --navy-soft: #2a4058;
    --white: #ffffff;
    --gold: #b8985e;
    --bordo: #6e2230;
    --text-dark: #101820;
    --line: rgba(14, 30, 44, 0.14);
    --container: 1120px;
    --shadow: 0 12px 34px rgba(12, 20, 30, 0.18);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Roboto", sans-serif;
    color: var(--text-dark);
    background: var(--white);
}

h1,
h2,
h3,
.logo-text {
    font-family: "Merriweather", serif;
}

a {
    color: inherit;
    text-decoration: none;
}

.container {
    width: min(calc(100% - 40px), var(--container));
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.96);
    border-bottom: 1px solid #dfe6ee;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(20, 36, 52, 0.08);
}

.top-strip {
    background: linear-gradient(150deg, var(--navy), #203347);
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.82rem;
}

.top-strip-inner {
    min-height: 36px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.top-strip-inner a {
    text-decoration: none;
}

.address-link {
    color: rgba(255, 255, 255, 0.92);
    font-weight: 400;
}

.address-link:hover {
    color: #f0dfba;
}

.phone-link {
    color: #e4d0a5;
    font-weight: 600;
    white-space: nowrap;
}

.phone-link:hover {
    color: #f3e4c7;
}

.header-inner {
    min-height: 66px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    position: relative;
}

.logo {
    display: inline-flex;
    align-items: center;
    margin-left: auto;
}

.logo img {
    width: clamp(150px, 18vw, 210px);
    height: auto;
    display: block;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 20px;
}

.site-nav a {
    color: #223248;
    font-size: 0.88rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    position: relative;
}

.site-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 100%;
    height: 2px;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 180ms ease;
    background: linear-gradient(90deg, var(--gold), var(--bordo));
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after {
    transform: scaleX(1);
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid #cdd8e6;
    background: #f8fbff;
    border-radius: 8px;
    padding: 8px;
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    margin: 5px 0;
    background: #203247;
}

.hero {
    position: relative;
    color: var(--white);
    background:
    linear-gradient(rgba(20, 34, 48, 0.64), rgba(14, 24, 36, 0.76)),
    radial-gradient(circle at 14% 16%, rgba(184, 152, 94, 0.22), transparent 40%),
    linear-gradient(130deg, #162434 0%, #203247 52%, #2d4763 100%);
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("https://source.unsplash.com/1600x900/?istanbul,justice");
    background-size: cover;
    background-position: center;
    filter: blur(4px);
    transform: scale(1.04);
    opacity: 0.3;
    z-index: 0;
}

.hero-inner {
    position: relative;
    z-index: 1;
    min-height: 64vh;
    display: grid;
    align-content: center;
    gap: 14px;
    padding: 64px 0;
}

.hero h1 {
    margin: 0;
    font-size: clamp(1.8rem, 4.1vw, 3.1rem);
    line-height: 1.26;
    max-width: 24ch;
}

.hero-subtitle {
    margin: 0;
    max-width: 56ch;
    font-size: clamp(1rem, 2vw, 1.22rem);
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.95);
}

.hero-cta {
    display: inline-flex;
    width: fit-content;
    margin-top: 6px;
    padding: 11px 22px;
    border-radius: 999px;
    background: linear-gradient(140deg, var(--gold), #cfb07a);
    color: #122233;
    font-weight: 700;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: transform 180ms ease, box-shadow 180ms ease;
}

.hero-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(8, 18, 28, 0.24);
}

.section {
    padding: 84px 0;
}

.section.alt {
    background: linear-gradient(180deg, #f8f9fb 0%, #f0f3f7 100%);
}

.section h2 {
    margin: 0 0 18px;
    font-size: clamp(1.62rem, 3.3vw, 2.2rem);
    color: var(--navy);
}

.section p {
    margin: 0;
    max-width: 78ch;
    line-height: 1.8;
    color: #2a3340;
}

.about-layout {
    display: grid;
    grid-template-columns: 400px minmax(0, 1fr);
    gap: 30px;
    align-items: start;
    margin-top: 18px;
}

.founder-photo {
    width: 100%;
    max-width: 400px;
    height: 500px;
    border-radius: 16px;
    border: 1px solid #d5deea;
    background: #eef2f7;
    box-shadow: 0 8px 20px rgba(20, 36, 52, 0.1);
    overflow: hidden;
}

.founder-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

.about-text-block {
    border: 1px solid #dde5ef;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: 0 10px 24px rgba(20, 36, 52, 0.08);
    padding: 26px;
}

.about-text-block h3 {
    margin: 0 0 16px;
    color: var(--navy);
    font-size: clamp(1.25rem, 2vw, 1.6rem);
}

.about-text-block p + p {
    margin-top: 14px;
}

.grid {
    display: grid;
    gap: 18px;
    margin-top: 26px;
}

.cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card,
.publication-item,
.contact-grid {
    border: 1px solid #dde5ef;
    border-radius: 16px;
    background: var(--white);
    box-shadow: var(--shadow);
}

.card,
.publication-item {
    padding: 24px;
}

.card {
    transition: box-shadow 180ms ease, transform 180ms ease;
    box-shadow: 0 6px 18px rgba(20, 36, 52, 0.08);
}

.card:hover {
    box-shadow: 0 10px 24px rgba(20, 36, 52, 0.12);
    transform: translateY(-2px);
}

.card-icon {
    width: 34px;
    height: 34px;
    color: var(--bordo);
    margin-bottom: 14px;
}

.card h3,
.publication-item h3 {
    margin: 0 0 10px;
    color: var(--navy);
    font-size: 1.2rem;
}

.card p,
.publication-item p {
    color: #364253;
    line-height: 1.72;
}

.publications {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.publication-manager {
    margin-top: 26px;
    border: 1px solid #dde5ef;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: 0 8px 20px rgba(20, 36, 52, 0.08);
    padding: 22px;
}

.publication-manager h3 {
    margin: 0;
    color: var(--navy);
    font-size: 1.15rem;
}

.publication-note {
    margin-top: 10px;
    color: #425065;
    max-width: 75ch;
}

.publication-form {
    margin-top: 16px;
}

.admin-auth {
    margin-top: 16px;
    padding: 14px;
    border: 1px solid #d9e2ee;
    border-radius: 12px;
    background: #f8fbff;
}

.admin-actions {
    display: flex;
    gap: 10px;
    margin-top: 8px;
    flex-wrap: wrap;
}

.admin-message {
    min-height: 1.2em;
    margin-top: 10px;
    color: #3b4a5e;
    font-size: 0.9rem;
}

.is-hidden {
    display: none;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 220px;
    gap: 12px;
}

.publication-form label {
    display: grid;
    gap: 7px;
    font-size: 0.94rem;
    color: #243445;
    margin-bottom: 12px;
}

.publication-form input,
.publication-form textarea {
    width: 100%;
    border: 1px solid #c9d4e2;
    border-radius: 10px;
    padding: 10px 12px;
    font: inherit;
    color: #1f2a37;
    background: #fbfcfe;
}

.publication-form textarea {
    resize: vertical;
}

.publication-form input:focus,
.publication-form textarea:focus {
    outline: 2px solid rgba(124, 34, 48, 0.22);
    border-color: #7c2230;
}

.form-button {
    border: 1px solid transparent;
    border-radius: 999px;
    background: linear-gradient(140deg, var(--navy), var(--navy-soft));
    color: #ffffff;
    font-weight: 600;
    padding: 10px 18px;
    cursor: pointer;
}

.publication-meta {
    display: inline-flex;
    margin-top: 8px;
    font-size: 0.85rem;
    color: #546377;
}

.publication-delete {
    margin-top: 14px;
    border: 1px solid #d5ddeb;
    border-radius: 999px;
    background: #f8fafd;
    color: #2a3748;
    padding: 7px 12px;
    cursor: pointer;
    font-size: 0.88rem;
}

.publication-delete:hover {
    background: #edf2f8;
}

.contact-grid {
    padding: 24px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 18px;
}

.contact-grid p {
    margin: 0;
    color: #2d3746;
}

.site-footer {
    padding: 22px 0;
    text-align: center;
    background: var(--navy);
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.94rem;
}

@media (max-width: 1100px) {
    .cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 920px) {
    .menu-toggle {
        display: inline-block;
        order: 1;
    }

    .site-nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        display: grid;
        gap: 0;
        background: rgba(255, 255, 255, 0.99);
        border-top: 1px solid #dbe3ef;
        max-height: 0;
        overflow: hidden;
        transition: max-height 220ms ease;
        order: 3;
    }

    .site-nav.is-open {
        max-height: 320px;
    }

    .site-nav a {
        padding: 14px 20px;
        border-bottom: 1px solid #e8eef6;
        color: #203247;
    }

    .logo {
        order: 2;
    }

    .top-strip-inner {
        min-height: 52px;
        flex-direction: column;
        justify-content: center;
        align-items: flex-start;
        padding: 8px 0;
        text-align: left;
    }

    .cards,
    .publications,
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .hero-inner {
        min-height: 68vh;
        padding: 64px 0;
    }

    .about-layout {
        grid-template-columns: 1fr;
    }

    .founder-photo {
        max-width: 100%;
        height: 420px;
    }
}

@media (max-width: 560px) {
    .container {
        width: min(calc(100% - 28px), var(--container));
    }

    .section {
        padding: 66px 0;
    }

    .hero-subtitle {
        font-size: 1rem;
    }
}