:root {
    --primary-color: #00D094;
    --secondary-color: #333;
    --background-light: #f8f9fa;
    --text-color: #333;
    --white: #ffffff;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    line-height: 1.6;
    color: var(--text-color);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
header {
    background: var(--white);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.logo img {
    height: 50px;
}

.menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.menu a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: var(--transition);
}

.menu a:hover,
.menu a.active {
    color: var(--primary-color);
}

.register-btn {
    padding: 10px 25px;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: var(--transition);
}

.register-btn:hover {
    background: #00b881;
}

.hamburger {
    display: none;
    cursor: pointer;
}

.hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background: var(--text-color);
    margin: 5px 0;
    transition: var(--transition);
}

/* Hero Section */
.about-hero {
    position: relative;
    background: url('images/history-bg.jpg') no-repeat center center;
    background-size: cover;
    height: 400px;
    margin-top: 0px;
    display: flex;
    align-items: center;
    text-align: center;
    color: var(--white);
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
}

.about-hero .container {
    position: relative;
    z-index: 2;
}

.about-hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.breadcrumb {
    font-size: 1.1rem;
}

.breadcrumb a {
    color: var(--primary-color);
    text-decoration: none;
}

/* History Sections */
.history-section {
    padding: 80px 0;
}

.history-section.alternate {
    background: var(--background-light);
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 40px;
    color: var(--text-color);
}

/* Family Tree Section */
.family-tree-container {
    background: var(--white);
    padding: 30px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    overflow-x: auto;
}

.search-box {
    margin-bottom: 30px;
    text-align: center;
}

.search-box input {
    padding: 12px 20px;
    width: 300px;
    border: 1px solid #ddd;
    border-radius: 5px;
    margin-right: 10px;
}

.search-btn {
    padding: 12px 25px;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: var(--transition);
}

.search-btn:hover {
    background: #00b881;
}

/* Tree Styles */
.tree {
    min-width: 800px;
    margin: 0 auto;
    padding: 20px 0;
}

.tree ul {
    padding-top: 20px;
    position: relative;
    transition: all 0.5s;
}

.tree li {
    float: left;
    text-align: center;
    list-style-type: none;
    position: relative;
    padding: 20px 5px 0 5px;
    transition: all 0.5s;
}

.tree li::before,
.tree li::after {
    content: '';
    position: absolute;
    top: 0;
    right: 50%;
    border-top: 1px solid #ccc;
    width: 50%;
    height: 20px;
}

.tree li::after {
    right: auto;
    left: 50%;
    border-left: 1px solid #ccc;
}

.tree li:only-child::after,
.tree li:only-child::before {
    display: none;
}

.tree li:only-child {
    padding-top: 0;
}

.tree li:first-child::before,
.tree li:last-child::after {
    border: 0 none;
}

.tree li:last-child::before {
    border-right: 1px solid #ccc;
    border-radius: 0 5px 0 0;
}

.tree li:first-child::after {
    border-radius: 5px 0 0 0;
}

.tree ul ul::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    border-left: 1px solid #ccc;
    width: 0;
    height: 20px;
}

.tree li a {
    border: 1px solid #ccc;
    padding: 8px 15px;
    text-decoration: none;
    color: var(--text-color);
    font-size: 14px;
    display: inline-block;
    border-radius: 5px;
    transition: all 0.5s;
}

.tree li a:hover,
.tree li a:hover + ul li a {
    background: var(--primary-color);
    color: var(--white);
    border: 1px solid var(--primary-color);
}

.tree li a:hover + ul li::after,
.tree li a:hover + ul li::before,
.tree li a:hover + ul::before,
.tree li a:hover + ul ul::before {
    border-color: var(--primary-color);
}

/* Timeline Section */
.timeline {
    max-width: 800px;
    margin: 0 auto;
}

.timeline-item {
    background: var(--white);
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 30px;
    box-shadow: var(--shadow);
}

.timeline-item .date {
    color: var(--primary-color);
    font-weight: bold;
    margin-bottom: 10px;
}

/* Personalities Grid */
.personalities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.personality-card {
    background: var(--white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.image-container {
    height: 250px;
    overflow: hidden;
}

.image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.personality-card h3 {
    padding: 20px 20px 10px;
}

.personality-card p {
    padding: 0 20px 20px;
}

.learn-more {
    margin: 0 20px 20px;
    padding: 10px 25px;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: var(--transition);
}

/* Milestones */
.milestones {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.milestone-card {
    background: var(--white);
    padding: 25px;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

/* Downloads Grid */
.downloads-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.download-card {
    background: var(--white);
    padding: 25px;
    border-radius: 10px;
    text-align: center;
    box-shadow: var(--shadow);
}

.document-icon {
    font-size: 40px;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.download-btn {
    padding: 10px 25px;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: var(--transition);
}

/* Footer */
footer {
    background: var(--secondary-color);
    color: var(--white);
    padding: 60px 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-about img {
    height: 50px;
    margin-bottom: 20px;
}

.footer-links ul {
    list-style: none;
}

.footer-links a {
    color: var(--white);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary-color);
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    color: var(--white);
    font-size: 20px;
    transition: var(--transition);
}

.social-icons a:hover {
    color: var(--primary-color);
}

.newsletter-form input {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: none;
    border-radius: 5px;
}

.newsletter-form button {
    width: 100%;
    padding: 10px;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: var(--transition);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

/* Responsive Design */
@media screen and (max-width: 992px) {
    .menu {
        display: none;
    }

    .hamburger {
        display: block;
    }

    .menu.active {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        padding: 20px;
        box-shadow: var(--shadow);
    }

    .family-tree-container {
        padding: 20px;
    }
}

@media screen and (max-width: 768px) {
    .about-hero {
        height: 300px;
    }

    .about-hero h1 {
        font-size: 2.5rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .search-box input {
        width: 100%;
        margin-bottom: 10px;
    }

    .search-btn {
        width: 100%;
    }

    .tree {
        min-width: 600px;
    }

    .personalities-grid,
    .milestones,
    .downloads-grid {
        grid-template-columns: 1fr;
    }
}

@media screen and (max-width: 480px) {
    .about-hero h1 {
        font-size: 2rem;
    }

    .section-title {
        font-size: 1.8rem;
    }

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

    .family-tree-container {
        padding: 15px;
    }
}