/* CSS Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colour palette */
    --primary-blue: #1a5f7a;
    --primary-blue-light: #2a7a9a;
    --accent-orange: #ff7e30;
    --accent-yellow: #ffc145;
    --light-bg: #f8f9fa;
    --dark-text: #2d3436;
    --medium-text: #636e72;
    --light-text: #b2bec3;
    --white: #ffffff;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 8px 20px rgba(0, 0, 0, 0.12);
    --border-radius: 8px;
    --transition: all 0.3s ease;
    /* Typography */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    --font-serif: 'Playfair Display', Georgia, serif;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.6;
    color: var(--dark-text);
    background-color: var(--white);
    overflow-x: hidden;
}

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

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--font-serif);
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
    color: var(--primary-blue);
}

h3 {
    font-size: 1.5rem;
    color: var(--primary-blue);
}

p {
    margin-bottom: 1.5rem;
}

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

a:hover {
    color: var(--accent-orange);
}

/* Skip link */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-blue);
    color: white;
    padding: 8px 16px;
    z-index: 1000;
    border-radius: var(--border-radius);
}

.skip-link:focus {
    top: 10px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: var(--border-radius);
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--primary-blue);
    color: var(--white);
}

.btn-primary:hover {
    background-color: var(--primary-blue-light);
    color: var(--white);
    box-shadow: var(--shadow-hover);
}

.btn-secondary {
    background-color: transparent;
    color: var(--primary-blue);
    border: 2px solid var(--primary-blue);
}

.btn-secondary:hover {
    background-color: var(--primary-blue);
    color: var(--white);
}

/* Header & Navigation */
.header {
    background-color: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
}

.logo-image img {
    display: block;
    width: 50px;
    height: 50px;
}

.logo-text h1 {
    font-size: 1.5rem;
    margin: 0;
    color: var(--primary-blue);
    line-height: 1.2;
    display: flex;
    flex-direction: column;
}

.logo-line1,
.logo-line2 {
    display: block;
}

.logo-line1 {
    margin-bottom: 2px;
}

.logo-line2 {
    font-size: 0.9em;
    color: var(--medium-text);
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--primary-blue);
    cursor: pointer;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 20px;
}

.nav-list a {
    font-weight: 500;
    color: var(--dark-text);
    font-size: 0.95rem;
    white-space: nowrap;
}

.nav-list a:hover {
    color: var(--accent-orange);
}

/* Hero Section */
.hero {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.hero .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}

@media (min-width: 992px) {
    .hero .container {
        flex-direction: row;
    }
}

.hero-content {
    flex: 1;
}

.hero-title {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: var(--primary-blue);
}

.hero-text {
    font-size: 1.1rem;
    color: var(--medium-text);
    margin-bottom: 30px;
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.hero-image {
    flex: 1;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-hover);
}

.hero-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Section Common */
.section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 20px;
}

.section-subtitle {
    text-align: center;
    color: var(--medium-text);
    max-width: 700px;
    margin: 0 auto 50px;
}

/* About Us */
.about-content {
    display: flex;
    flex-direction: column;
    gap: 40px;
    align-items: center;
}

@media (min-width: 768px) {
    .about-content {
        flex-direction: row;
    }
}

.about-text {
    flex: 1;
}

.about-image {
    flex: 1;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.about-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Programmes & Classes */
.programme-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-top: 40px;
}

@media (min-width: 768px) {
    .programme-cards {
        grid-template-columns: repeat(3, 1fr);
    }
}

.card {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 30px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.card-icon {
    font-size: 2.5rem;
    color: var(--accent-orange);
    margin-bottom: 20px;
}

.card-title {
    margin-bottom: 15px;
}

.card-text {
    color: var(--medium-text);
    flex-grow: 1;
}

.card-list {
    list-style: none;
    margin-top: 20px;
}

.card-list li {
    margin-bottom: 10px;
    padding-left: 24px;
    position: relative;
}

.card-list li:before {
    content: '✓';
    color: var(--accent-orange);
    font-weight: bold;
    position: absolute;
    left: 0;
}

/* Community Centre */
.community-content {
    display: flex;
    flex-direction: column;
    gap: 40px;
    align-items: center;
}

@media (min-width: 768px) {
    .community-content {
        flex-direction: row;
    }
}

.community-image {
    flex: 1;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.community-image img {
    width: 100%;
    height: auto;
    display: block;
}

.community-text {
    flex: 1;
}

/* How to Join */
.join-steps {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin: 50px 0;
}

@media (min-width: 768px) {
    .join-steps {
        grid-template-columns: repeat(3, 1fr);
    }
}

.step {
    text-align: center;
    padding: 30px;
    border-radius: var(--border-radius);
    background: var(--light-bg);
    transition: var(--transition);
}

.step:hover {
    background: var(--white);
    box-shadow: var(--shadow);
}

.step-number {
    display: inline-block;
    width: 50px;
    height: 50px;
    line-height: 50px;
    background: var(--primary-blue);
    color: white;
    border-radius: 50%;
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 20px;
}

.step-title {
    margin-bottom: 15px;
}

.join-notes {
    background: var(--light-bg);
    padding: 30px;
    border-radius: var(--border-radius);
    margin-top: 40px;
}

/* For Parents & Carers */
.parents-content {
    display: flex;
    flex-direction: column;
    gap: 40px;
    align-items: center;
}

@media (min-width: 768px) {
    .parents-content {
        flex-direction: row;
    }
}

.parents-text {
    flex: 1;
}

.parents-image {
    flex: 1;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.parents-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* News & Events */
.news-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-top: 40px;
}

@media (min-width: 768px) {
    .news-cards {
        grid-template-columns: repeat(3, 1fr);
    }
}

.news-card {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 30px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.news-date {
    font-size: 0.9rem;
    color: var(--accent-orange);
    font-weight: 600;
    margin-bottom: 10px;
}

.news-title {
    margin-bottom: 15px;
}

.news-text {
    color: var(--medium-text);
    flex-grow: 1;
    margin-bottom: 20px;
}

.news-link {
    color: var(--primary-blue);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.news-link:hover {
    color: var(--accent-orange);
    gap: 12px;
}

/* Contact & Location */
.contact-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 50px;
}

@media (min-width: 992px) {
    .contact-content {
        grid-template-columns: 1fr 1fr;
    }
}

.contact-item {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.contact-item i {
    font-size: 1.5rem;
    color: var(--accent-orange);
    margin-top: 5px;
}

.contact-item h3 {
    margin-bottom: 5px;
}

.contact-form {
    background: var(--light-bg);
    padding: 30px;
    border-radius: var(--border-radius);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--light-text);
    border-radius: var(--border-radius);
    font-family: var(--font-sans);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(26, 95, 122, 0.1);
}

.form-note {
    margin-top: 15px;
    font-size: 0.9rem;
    color: var(--medium-text);
}

/* Footer */
.footer {
    background: var(--primary-blue);
    color: var(--white);
    padding: 60px 0 30px;
}

.footer a {
    color: var(--white);
}

.footer a:hover {
    color: var(--accent-yellow);
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    margin-bottom: 50px;
}

@media (min-width: 768px) {
    .footer-content {
        grid-template-columns: repeat(3, 1fr);
    }
}

.footer-logo h3 {
    color: var(--white);
    margin-bottom: 15px;
}

.footer-links h4,
.footer-legal h4 {
    color: var(--white);
    margin-bottom: 20px;
}

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

.footer-links li {
    margin-bottom: 10px;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 15px;
}

@media (min-width: 768px) {
    .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }
}

.design-credit {
    font-size: 0.9rem;
}

/* Responsive Navigation */
@media (max-width: 767px) {
    .nav-toggle {
        display: block;
    }

    .nav {
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background: var(--white);
        box-shadow: var(--shadow);
        padding: 20px;
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: var(--transition);
    }

    .nav.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .nav-list {
        flex-direction: column;
        gap: 15px;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.75rem;
    }

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

    .section {
        padding: 60px 0;
    }
}

/* Accessibility: Focus styles */
button:focus,
input:focus,
textarea:focus,
a:focus {
    outline: 2px solid var(--accent-orange);
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .header,
    .hero-buttons,
    .contact-form,
    .footer-bottom .design-credit {
        display: none;
    }

    body {
        font-size: 12pt;
        line-height: 1.4;
    }

    .container {
        max-width: 100%;
        padding: 0;
    }

    .section {
        padding: 20pt 0;
        page-break-inside: avoid;
    }

    a {
        color: #000;
        text-decoration: underline;
    }

    .btn {
        border: 1pt solid #000;
    }
}
