:root {
    --primary-dark: #0b1a30;
    --secondary-dark: #162a45;
    --gold-classic: #b89047;
    --gold-light: #f7f4eb;
    --text-main: #222222;
    --text-muted: #555555;
    --bg-base: #f9fafb;
    --white: #ffffff;
    --border-line: #e5e7eb;
}

html { scroll-behavior: smooth; }

body { 
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, Arial, sans-serif; 
    line-height: 1.7; 
    color: var(--text-main); 
    margin: 0; 
    padding: 0; 
    background-color: var(--bg-base); 
    -webkit-font-smoothing: antialiased;
}

/* Навігаційна панель */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: var(--white);
    border-bottom: 2px solid var(--gold-classic);
    box-shadow: 0 4px 20px rgba(0,0,0,0.04);
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 3rem;
    box-sizing: border-box;
}

.nav-logo { 
    font-family: 'Times New Roman', Georgia, serif;
    font-weight: 700; 
    font-size: 1.3rem; 
    color: var(--primary-dark); 
    text-decoration: none;
    letter-spacing: 1px;
}

.nav-logo span { color: var(--gold-classic); }

.nav-links { list-style: none; display: flex; gap: 2rem; margin: 0; padding: 0; }
.nav-links a { 
    text-decoration: none; 
    color: var(--text-main); 
    font-weight: 600; 
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: color 0.3s ease; 
}
.nav-links a:hover { color: var(--gold-classic); }

/* Кнопка мобільного меню (прихована на ПК) */
.menu-toggle {
    display: none;
    font-size: 1.8rem;
    color: var(--primary-dark);
    cursor: pointer;
    user-select: none;
}

/* Офіційний Hero-блок */
header { 
    background-color: var(--primary-dark); 
    padding: 11rem 2rem 7rem; 
    text-align: center; 
    position: relative;
    background-image: linear-gradient(135deg, #0b1a30 0%, #050d1a 100%);
}

header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 3px;
    background-color: var(--gold-classic);
}

header h1 { 
    font-family: 'Times New Roman', Georgia, serif;
    margin-bottom: 2rem; 
    font-size: 2.4rem; 
    font-weight: 400; 
    letter-spacing: 1px;
    line-height: 1.3;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
    color: var(--white);
}

header p { 
    font-size: 1.15rem; 
    max-width: 950px; 
    margin: 0 auto; 
    color: #f8f9fa;
    text-align: justify;
    font-weight: 300;
    line-height: 1.8;
    text-shadow: 0 1px 3px rgba(0,0,0,0.6);
}

/* Контентний простір */
main { max-width: 1140px; margin: 3rem auto; padding: 0 1.5rem; }

section { 
    background: var(--white); 
    padding: 3.5rem; 
    margin-bottom: 2.5rem; 
    border-radius: 4px; 
    border: 1px solid var(--border-line);
    box-shadow: 0 10px 30px rgba(0,0,0,0.01);
    scroll-margin-top: 100px; 
}

h2 { 
    font-family: 'Times New Roman', Georgia, serif;
    color: var(--primary-dark); 
    font-size: 2rem;
    font-weight: 400;
    margin-top: 0;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 15px;
}

h2::after { content: ''; flex-grow: 1; height: 1px; background-color: var(--border-line); }

h3 { 
    font-family: 'Times New Roman', Georgia, serif;
    color: var(--secondary-dark); 
    font-size: 1.4rem;
    font-weight: 600;
    margin-top: 2rem; 
    margin-bottom: 1rem;
    border-left: 3px solid var(--gold-classic);
    padding-left: 12px;
}

p { margin-bottom: 1.5rem; text-align: justify; color: var(--text-main); }
ul { padding-left: 1.5rem; margin-bottom: 1.5rem; }
li { margin-bottom: 0.7rem; }

/* Картки */
.founders-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
    gap: 2rem; 
    margin-top: 2rem; 
}

.founder-card { 
    background: var(--white); 
    padding: 2rem; 
    border-radius: 4px; 
    border: 1px solid var(--border-line);
    border-top: 3px solid var(--gold-classic);
    box-shadow: 0 5px 15px rgba(0,0,0,0.02);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
    box-sizing: border-box;
}

.founder-card:hover { transform: translateY(-4px); box-shadow: 0 15px 35px rgba(184,144,71,0.08); }

.founder-photo { 
    width: 120px; 
    height: 120px; 
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--gold-classic);
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
    margin: 0 auto 1.5rem auto; 
    display: block;
    flex-shrink: 0;
}

.founder-name { 
    font-family: 'Times New Roman', Georgia, serif;
    font-size: 1.25rem; 
    font-weight: 700; 
    color: var(--primary-dark); 
    text-align: center;
    margin-bottom: 1rem; 
    
    /* Додаємо фіксовану мінімальну висоту, достатню для 4-х рядків (найдовша назва) */
    min-height: 6.5rem; 
    
    display: flex;
    /* Змінюємо вирівнювання, щоб усі заголовки починалися строго з однієї верхньої лінії */
    align-items: flex-start; 
    justify-content: center;
}

.founder-regalia { 
    font-size: 0.9rem; 
    color: var(--text-muted); 
    margin-bottom: 1.5rem; 
    text-align: justify;
    line-height: 1.6;
    border-top: 1px dashed var(--border-line);
    padding-top: 1rem;
    flex-grow: 1; 
}

.founder-link { 
    display: block; 
    text-align: center;
    font-size: 0.9rem; 
    color: var(--gold-classic); 
    text-decoration: none; 
    font-weight: 600; 
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: color 0.3s ease;
    margin-top: auto; 
}
.founder-link:hover { color: var(--primary-dark); }

/* Керівництво */
.leadership-container { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-top: 1.5rem; }
.leadership-block { background: var(--gold-light); padding: 2rem; border-left: 4px solid var(--gold-classic); border-radius: 2px; }
.leadership-title { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 1px; color: var(--gold-classic); font-weight: 700; margin-bottom: 0.5rem; display: block; }
.leadership-block strong { font-family: 'Times New Roman', Georgia, serif; font-size: 1.3rem; color: var(--primary-dark); font-weight: 400; }
.leadership-block p { margin-top: 0.5rem; margin-bottom: 0; font-size: 0.95rem; color: var(--text-muted); }

/* Реєстр офіційних документів */
.docs-list { list-style: none; padding: 0; margin: 0; }
.docs-list li { 
    margin-bottom: 1rem; 
    background: var(--white); 
    padding: 1.5rem; 
    border-radius: 4px; 
    border: 1px solid var(--border-line);
    display: flex; 
    align-items: center; 
    justify-content: space-between;
    transition: background-color 0.3s ease;
}
.docs-list li:hover { background-color: var(--gold-light); }
.doc-meta { display: flex; align-items: flex-start; gap: 15px; flex-grow: 1; }
.doc-icon { font-size: 1.5rem; color: var(--gold-classic); margin-top: 2px; }
.doc-text { padding-right: 15px; }
.docs-list a.doc-title { 
    text-decoration: none; 
    color: var(--primary-dark); 
    font-weight: 600; 
    font-size: 1.05rem;
    display: block;
}
.docs-list a.doc-title:hover { color: var(--gold-classic); }
.doc-desc { font-size: 0.85rem; color: var(--text-muted); display: block; margin-top: 0.4rem; }

.btn-view {
    border: 1px solid var(--gold-classic);
    padding: 8px 20px;
    font-size: 0.85rem;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
    color: var(--gold-classic);
    text-decoration: none;
    transition: all 0.3s ease;
    background: transparent;
    white-space: nowrap;
    flex-shrink: 0;
}
.btn-view:hover, .btn-view:active {
    background-color: var(--gold-classic);
    color: var(--primary-dark);
}

/* --- АДАПТИВНІСТЬ ДЛЯ МОБІЛЬНИХ (ДО 868px) --- */
@media (max-width: 868px) {
    nav { padding: 1rem 1.5rem; justify-content: space-between; flex-wrap: wrap; }
    .menu-toggle { display: block; }
    
    .nav-links { 
        display: none;
        flex-direction: column; 
        width: 100%; 
        background-color: var(--white);
        position: absolute;
        top: 100%;
        left: 0;
        padding: 1rem 0;
        box-shadow: 0 10px 15px rgba(0,0,0,0.05);
        border-top: 1px solid var(--border-line);
    }
    .nav-links.active { display: flex; }
    .nav-links li { text-align: center; margin: 0.5rem 0; }
    .nav-links a { font-size: 1.1rem; display: block; padding: 0.5rem; }

    header { padding: 9rem 1rem 3rem; }
    header h1 { font-size: 1.8rem; }
    header p { text-align: left; }
    section { padding: 2rem 1.2rem; }
    .leadership-container { grid-template-columns: 1fr; }
    
    .docs-list li {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.2rem;
    }
    .btn-view {
        align-self: flex-start;
        width: auto;
    }
}