@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&family=Lato:wght@400;700&family=Caveat&display=swap');

:root {
    --primary-color: #0a3a64; /* Dark Blue */
    --primary-medium-bg: #3e6b93; /* A mid-tone blue for section headers */
    --primary-light-bg: #D6EAF8; /* A very light, subtle blue */
    --secondary-color: #E6E6FA; /* Lavender */
    --background-color: #F8F9FA;
    --text-color: #343A40;
    --header-bg-color: #FFFFFF;
    --footer-bg-color: #343A40;
    --footer-text-color: #F8F9FA;
    --font-header: 'Montserrat', sans-serif;
    --font-body: 'Lato', sans-serif;
    --font-tagline: 'Caveat', cursive;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 62.5%;
    font-family: var(--font-body);
    color: var(--text-color);
    background-color: var(--background-color);
}

body {
    font-size: 1.6rem;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-header);
    font-weight: 700;
    color: var(--primary-color);
}

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

a:hover {
    text-decoration: underline;
}

.header {
    background-color: var(--header-bg-color);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.logo-container {
    display: flex;
    align-items: center;
}

.nav-logo > img {
    height: 140px;
}

.nav-tagline {
    font-family: var(--font-tagline);
    font-size: 2.2rem;
    color: var(--text-color);
    margin-left: 2rem;
    line-height: 1.4;
    text-align: center;
}

.nav-menu {
    display: flex;
    list-style: none;
}

.nav-item {
    margin-left: 3rem;
}

.nav-link {
    font-size: 1.6rem;
    font-weight: 700;
    font-family: var(--font-header);
    color: var(--text-color);
    transition: color 0.3s;
}

.nav-link:hover {
    color: var(--primary-color);
    text-decoration: none;
}

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

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background-color: var(--text-color);
    transition: all 0.3s ease-in-out;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 4rem 2rem;
}

.page-title {
    font-size: 3.6rem;
    text-align: center;
    margin-bottom: 4rem;
}

/* Index Page */
.hero {
    text-align: center;
    padding: 5rem 2rem;
    background-color: var(--secondary-color);
}

.hero h1 {
    font-size: 4.2rem;
}

.hero p {
    font-size: 2rem;
    margin-bottom: 2rem;
}

.cta-button {
    display: inline-block;
    padding: 1.2rem 2.4rem;
    background-color: var(--primary-light-bg);
    color: var(--primary-color);
    font-family: var(--font-header);
    font-weight: 700;
    border-radius: 5px;
    transition: background-color 0.3s;
    border: 1px solid var(--primary-light-bg);
}

.cta-button:hover {
    background-color: #b9d7ea;
    color: var(--primary-color);
    text-decoration: none;
}

.featured-images {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.featured-images img {
    width: 100%;
    height: auto;
    border-radius: 5px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* About Page */
.about-section-container {
    background-color: var(--secondary-color);
    padding: 4rem 2rem;
    border-radius: 5px;
}

.about-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.about-section img {
    width: 80%;
    border-radius: 5px;
    display: block;
    margin: 0 auto;
}

.values-list {
    text-align: left;
    margin-top: 3rem;
    font-weight: bold;
}

.values-list p {
    margin-bottom: 0.5rem;
}

.values-summary {
    font-size: 1.8rem;
    margin-top: 1rem;
}

/* Gallery Page */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.gallery-item img {
    width: 100%;
    height: auto;
    border-radius: 5px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

.gallery-item img:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
}

/* Lightbox styles */
.lightbox {
    display: none;
    position: fixed;
    z-index: 1001;
    padding-top: 60px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.9);
}

.lightbox-content {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 700px;
}

.lightbox-close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
}

.lightbox-close:hover,
.lightbox-close:focus {
    color: #bbb;
    text-decoration: none;
    cursor: pointer;
}

.lightbox-prev, .lightbox-next {
    cursor: pointer;
    position: absolute;
    top: 50%;
    width: auto;
    padding: 16px;
    margin-top: -50px;
    color: white;
    font-weight: bold;
    font-size: 20px;
    transition: 0.6s ease;
    border-radius: 0 3px 3px 0;
    user-select: none;
    -webkit-user-select: none;
}

.lightbox-next {
    right: 0;
    border-radius: 3px 0 0 3px;
}

.lightbox-prev:hover, .lightbox-next:hover {
    background-color: rgba(0,0,0,0.8);
}


/* Price List & Rules */
.table-container {
    overflow-x: auto;
}

.custom-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 3rem;
    font-size: 1.6rem;
}

.custom-table th, .custom-table td {
    padding: 1.5rem;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.custom-table th {
    background-color: var(--primary-light-bg);
    color: var(--primary-color);
    font-family: var(--font-header);
}

.table-section-header {
    background-color: var(--primary-medium-bg) !important;
    font-size: 2rem;
    text-align: center !important;
    color: white !important;
}

.custom-table tbody:nth-of-type(even) {
    background-color: #f2f2f2;
}

.custom-table tbody:hover {
    background-color: var(--secondary-color);
}

.rules-list {
    list-style: none;
    padding: 0;
}

.rule-item {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    padding-left: 2rem;
    position: relative;
}

.rule-item::before {
    content: '✓';
    color: var(--primary-color);
    position: absolute;
    left: 0;
}

.price-includes-section {
    margin-top: 4rem;
    padding: 2rem;
    background-color: var(--secondary-color);
    border-radius: 5px;
}

.price-includes-section h3 {
    margin-bottom: 1rem;
}

.price-includes-section ul {
    list-style: none;
    padding: 0;
}

.price-includes-section li {
    margin-bottom: 0.5rem;
}


/* Schedule Page */
.schedule-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.schedule-day {
    border: 1px solid #ddd;
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.schedule-day h3 {
    background-color: var(--primary-light-bg);
    color: var(--primary-color);
    padding: 1rem;
    font-size: 1.8rem;
    border-radius: 5px 5px 0 0;
    text-align: center;
}

.schedule-day .schedule-body {
    padding: 1.5rem;
    text-align: center;
}

/* Contact Page */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr; /* Give more space to the map */
    gap: 4rem;
    align-items: start;
}

.contact-details > * {
    margin-bottom: 1.5rem;
}

.contact-details > *:last-child {
    margin-bottom: 0;
}

.social-links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.social-icon {
    width: 24px;
    height: 24px;
    transition: transform 0.3s;
}

.social-icon:hover {
    transform: scale(1.2);
}

.map-container {
    width: 100%;
    height: 100%;
    min-height: 450px; /* Increased minimum height */
}

.map-responsive {
    overflow: hidden;
    position: relative;
    width: 100%;
    height: 100%;
}

.map-responsive iframe {
    left: 0;
    top: 0;
    height: 100%;
    width: 100%;
    position: absolute;
    border-radius: 5px;
    border: 0;
}

/* Responsive */
@media only screen and (max-width: 768px) {
    .navbar {
        position: relative;
    }

    .logo-container {
        flex-grow: 1;
    }

    .nav-tagline {
        font-size: 1.4rem;
        margin-left: 1rem;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 100px;
        flex-direction: column;
        background-color: var(--header-bg-color);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-item {
        margin: 2.5rem 0;
    }

    .hamburger {
        display: block;
    }

    .hamburger.active .bar:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .nav-logo > img {
        height: 100px;
    }

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

    .about-section img {
        width: 100%;
    }

    .map-container {
        height: 300px;
    }

    .lightbox-content {
        width: 95%;
    }

    /* Responsive table for price list */
    .custom-table thead {
        display: none;
    }

    .collapsible-header {
        cursor: pointer;
        position: relative;
    }

    .collapsible-header.collapsed::after {
        content: '+';
    }

    .collapsible-header:not(.collapsed)::after {
        content: '−';
    }

    .collapsible-header::after {
        position: absolute;
        right: 2rem;
        font-size: 2.5rem;
        font-weight: bold;
    }

    .custom-table tbody {
        display: none;
    }

    .custom-table.active tbody {
        display: block;
    }

    .custom-table, .custom-table tbody, .custom-table tr, .custom-table td {
        display: block;
        width: 100%;
    }

    .custom-table tr {
        margin-bottom: 1.5rem;
        border: 1px solid #ddd;
        border-radius: 5px;
        box-shadow: 0 2px 4px rgba(0,0,0,0.05);
        overflow: hidden;
    }

    .custom-table td[data-label] {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        padding: 1.5rem;
        border-bottom: 1px solid #eee;
        text-align: right;
    }

    .custom-table td:last-child {
        border-bottom: 0;
    }

    .custom-table td[data-label]::before {
        content: attr(data-label);
        text-align: left;
        font-weight: bold;
        font-family: var(--font-header);
        margin-right: 1rem;
        white-space: normal;
    }

    .custom-table td:empty {
        display: none;
    }

    .custom-table td[data-label="Grupa"],
    .custom-table td[data-label="Rodzaj zajęć"],
    .custom-table td[data-label="Rodzaj"] {
        background-color: var(--primary-light-bg);
    }

    /* Fix for single-column rows */
    .custom-table td:not([data-label]) {
        text-align: left;
        padding: 1.5rem;
    }

    .custom-table caption {
        display: block;
    }
}

.enrollment-info {
    color: #663399; /* Rebecca Purple */
}
