/* Basic reset */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
    color: #222;
    background-color: #f7f7f7;
}

/* Layout helpers */
.container {
    width: 100%;
    max-width: 980px;
    margin: 0 auto;
    padding: 0 1.2rem;
}

/* Header */
.site-header {
    background: linear-gradient(135deg, #003b5c, #005f86);
    color: #fff;
    padding-top: 1.5rem;
    padding-bottom: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding-bottom: 1rem;
}

.title-block h1 {
    font-size: 2.2rem;
    margin-bottom: 0.3rem;
}

.subtitle {
    font-size: 0.95rem;
    opacity: 0.95;
}

.portrait img {
    display: block;
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 50%;
    border: 3px solid rgba(255, 255, 255, 0.9);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.35);
}

/* Navigation */
.main-nav {
    background: rgba(0, 0, 0, 0.12);
    margin-top: 0.5rem;
}

.nav-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: flex-start;
    padding: 0.6rem 0;
}

.main-nav a {
    color: #e8f4ff;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    position: relative;
}

.main-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -0.25rem;
    width: 0;
    height: 2px;
    background-color: #ffd166;
    transition: width 0.2s ease-out;
}

.main-nav a:hover::after,
.main-nav a:focus::after {
    width: 100%;
}

/* Main content */
.main-content {
    background: #ffffff;
    margin-top: 1.5rem;
    margin-bottom: 2rem;
    padding: 2rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.section + .section {
    margin-top: 2.5rem;
    border-top: 1px solid #e0e0e0;
    padding-top: 2rem;
}

.section h2 {
    font-size: 1.6rem;
    margin-bottom: 0.6rem;
    color: #003b5c;
}

.section h3 {
    font-size: 1.15rem;
    margin-top: 1.2rem;
    margin-bottom: 0.3rem;
    color: #005f86;
}

.section p {
    margin-bottom: 0.9rem;
}

.section ul {
    list-style: disc;
    padding-left: 1.5rem;
    margin-top: 0.2rem;
    margin-bottom: 0.9rem;
}

.section li + li {
    margin-top: 0.25rem;
}

/* Links */
a {
    color: #005f86;
}

a:hover,
a:focus {
    color: #003b5c;
    text-decoration: underline;
}

/* Contact grid */
.contact-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 2rem;
}

/* Footer */
.site-footer {
    background: #003b5c;
    color: #e8f4ff;
    padding: 0.75rem 0;
    font-size: 0.85rem;
}

.site-footer p {
    text-align: center;
}

/* Responsive */
@media (max-width: 720px) {
    .header-content {
        flex-direction: column-reverse;
        align-items: flex-start;
    }

    .portrait img {
        width: 120px;
        height: 120px;
    }

    .main-content {
        padding: 1.5rem 1.1rem;
    }

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

    .nav-links {
        justify-content: center;
    }

    .title-block h1 {
        font-size: 1.8rem;
    }
}
