/* =====================================================
   BRITISH EDUCATION CONSULTANTS
   Clean, Professional, Distinctive with Character
   ===================================================== */

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

:root {
    /* Colors - Deep navy and warm cream */
    --navy: #0a1628;
    --navy-light: #1a2a44;
    --cream: #f8f6f0;
    --cream-dark: #ebe8e0;
    --red: #c41230;
    --red-light: #e8324a;
    --gold: #c9a227;
    --text: #2d3748;
    --text-light: #5a6577;
    --white: #ffffff;
    
    /* Typography */
    --font-serif: 'Instrument Serif', Georgia, serif;
    --font-sans: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    
    /* Spacing */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2.5rem;
    --space-xl: 4rem;
    --space-2xl: 6rem;
    --space-3xl: 8rem;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text);
    background: var(--cream);
    -webkit-font-smoothing: antialiased;
}

/* Selection */
::selection {
    background: var(--red);
    color: var(--white);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-md);
}

/* =====================================================
   HEADER
   ===================================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: var(--space-sm) 0;
    background: var(--cream);
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
}

.header.scrolled {
    background: rgba(248, 246, 240, 0.95);
    backdrop-filter: blur(10px);
    border-bottom-color: var(--cream-dark);
    box-shadow: 0 4px 20px rgba(10, 22, 40, 0.05);
}

.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-md);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-lg);
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    text-decoration: none;
    color: var(--navy);
}

.logo-mark {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--white);
    background: var(--navy);
    padding: 0.5rem 0.9rem;
    letter-spacing: -0.02em;
    position: relative;
    overflow: hidden;
}

.logo-mark::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 12px;
    height: 100%;
    background: var(--red);
}

.logo-text {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
    display: none;
}

@media (min-width: 640px) {
    .logo-text {
        display: block;
    }
}

/* Navigation */
.nav {
    display: none;
    align-items: center;
    gap: var(--space-lg);
}

@media (min-width: 768px) {
    .nav {
        display: flex;
    }
}

.nav a {
    text-decoration: none;
    color: var(--text-light);
    font-size: 0.9rem;
    font-weight: 500;
    padding: var(--space-xs) 0;
    position: relative;
    transition: color 0.2s ease;
}

.nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--red);
    transition: width 0.3s ease;
}

.nav a:hover,
.nav a.active {
    color: var(--navy);
}

.nav a:hover::after,
.nav a.active::after {
    width: 100%;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 0.875rem 1.75rem;
    font-family: var(--font-sans);
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 0;
    border: none;
    cursor: pointer;
    transition: all 0.25s ease;
    position: relative;
    overflow: hidden;
}

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

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--red);
    transition: left 0.3s ease;
    z-index: 0;
}

.btn-primary:hover::before {
    left: 0;
}

.btn-primary span,
.btn-primary {
    position: relative;
    z-index: 1;
}

.btn-outline {
    background: transparent;
    color: var(--navy);
    border: 2px solid var(--navy);
}

.btn-outline:hover {
    background: var(--navy);
    color: var(--white);
}

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

.btn-white:hover {
    background: var(--cream);
    transform: translateY(-2px);
}

.header .btn {
    display: none;
}

@media (min-width: 768px) {
    .header .btn {
        display: inline-flex;
    }
}

/* Mobile Toggle */
.mobile-toggle {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 8px;
    background: none;
    border: none;
    cursor: pointer;
}

@media (min-width: 768px) {
    .mobile-toggle {
        display: none;
    }
}

.mobile-toggle span {
    width: 24px;
    height: 2px;
    background: var(--navy);
    transition: all 0.3s ease;
}

/* =====================================================
   HERO
   ===================================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding: var(--space-3xl) 0;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-pattern {
    position: absolute;
    top: 0;
    right: 0;
    width: 50%;
    height: 100%;
    background: 
        linear-gradient(135deg, transparent 25%, var(--cream-dark) 25%, var(--cream-dark) 50%, transparent 50%, transparent 75%, var(--cream-dark) 75%);
    background-size: 60px 60px;
    opacity: 0.4;
}

.hero-accent {
    position: absolute;
    top: 20%;
    right: 10%;
    width: 300px;
    height: 300px;
    background: var(--red);
    opacity: 0.03;
    border-radius: 50%;
    filter: blur(80px);
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-xl);
    align-items: center;
    position: relative;
    z-index: 1;
}

@media (min-width: 900px) {
    .hero-grid {
        grid-template-columns: 1.1fr 0.9fr;
    }
}

.hero-content {
    max-width: 600px;
}

.hero-label {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--red);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    margin-bottom: var(--space-md);
}

.hero-label::before {
    content: '';
    width: 32px;
    height: 2px;
    background: var(--red);
}

.hero-title {
    font-family: var(--font-serif);
    font-size: clamp(2.5rem, 5.5vw, 3.75rem);
    font-weight: 400;
    line-height: 1.1;
    color: var(--navy);
    margin-bottom: var(--space-lg);
}

.hero-title em {
    font-style: italic;
    color: var(--red);
}

.hero-text {
    font-size: 1.125rem;
    color: var(--text-light);
    max-width: 480px;
    margin-bottom: var(--space-xl);
    line-height: 1.7;
}

.hero-actions {
    display: flex;
    gap: var(--space-sm);
    flex-wrap: wrap;
}

/* Hero Image */
.hero-image {
    position: relative;
    display: none;
}

@media (min-width: 900px) {
    .hero-image {
        display: block;
    }
}

.hero-image-main {
    position: relative;
    background: var(--white);
    padding: var(--space-sm);
    box-shadow: 0 25px 50px rgba(10, 22, 40, 0.15);
}

.hero-image-main img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    display: block;
}

.hero-image-badge {
    position: absolute;
    bottom: -20px;
    left: -20px;
    background: var(--navy);
    color: var(--white);
    padding: var(--space-md) var(--space-lg);
    font-family: var(--font-serif);
    font-size: 1.125rem;
}

.hero-image-badge span {
    display: block;
    font-family: var(--font-sans);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    opacity: 0.7;
    margin-bottom: 4px;
}

.hero-float {
    position: absolute;
    top: 40px;
    right: -30px;
    background: var(--red);
    color: var(--white);
    padding: var(--space-sm) var(--space-md);
    font-size: 0.85rem;
    font-weight: 600;
    transform: rotate(3deg);
}

/* =====================================================
   SECTIONS
   ===================================================== */
.section {
    padding: var(--space-3xl) 0;
    position: relative;
}

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

.section-cream {
    background: var(--cream);
}

.section-dark {
    background: var(--navy);
    color: var(--white);
}

.section-intro {
    max-width: 640px;
    margin-bottom: var(--space-2xl);
}

.section-label {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--red);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    margin-bottom: var(--space-sm);
}

.section-label::before {
    content: '';
    width: 24px;
    height: 2px;
    background: currentColor;
}

.section-dark .section-label {
    color: var(--gold);
}

.section-title {
    font-family: var(--font-serif);
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 400;
    line-height: 1.2;
    color: var(--navy);
}

.section-dark .section-title {
    color: var(--white);
}

.section-cta {
    margin-top: var(--space-xl);
}

.link-arrow {
    font-weight: 600;
    color: var(--navy);
    text-decoration: none;
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: gap 0.2s ease;
}

.link-arrow:hover {
    gap: 12px;
}

.section-dark .link-arrow {
    color: var(--gold);
}

/* =====================================================
   SERVICES LIST
   ===================================================== */
.services-list {
    display: grid;
    gap: 0;
    border: 1px solid var(--cream-dark);
}

.service-item {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: var(--space-lg);
    padding: var(--space-xl) var(--space-lg);
    background: var(--white);
    border-bottom: 1px solid var(--cream-dark);
    transition: all 0.3s ease;
    position: relative;
}

.service-item:last-child {
    border-bottom: none;
}

.service-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 4px;
    height: 0;
    background: var(--red);
    transition: height 0.3s ease;
}

.service-item:hover {
    background: var(--cream);
}

.service-item:hover::before {
    height: 100%;
}

.service-number {
    font-family: var(--font-serif);
    font-size: 2.5rem;
    color: var(--cream-dark);
    line-height: 1;
    transition: color 0.3s ease;
}

.service-item:hover .service-number {
    color: var(--red);
}

.service-content h3 {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--navy);
    margin-bottom: var(--space-sm);
}

.service-content p {
    color: var(--text-light);
    line-height: 1.7;
}

/* =====================================================
   ABOUT GRID
   ===================================================== */
.about-grid {
    display: grid;
    gap: var(--space-2xl);
    align-items: center;
}

@media (min-width: 768px) {
    .about-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.about-content p {
    color: rgba(255, 255, 255, 0.75);
    margin-bottom: var(--space-md);
    line-height: 1.8;
}

.about-image {
    position: relative;
}

.about-image img {
    width: 100%;
    height: 450px;
    object-fit: cover;
}

.about-image-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: var(--space-lg);
    background: linear-gradient(to top, rgba(10, 22, 40, 0.9), transparent);
}

.about-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: var(--space-lg);
}

.about-card h4 {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 400;
    margin-bottom: var(--space-md);
    color: var(--gold);
}

.focus-list {
    list-style: none;
}

.focus-list li {
    padding: var(--space-sm) 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.focus-list li::before {
    content: '→';
    color: var(--gold);
}

.focus-list li:last-child {
    border-bottom: none;
}

/* =====================================================
   PARTNERS / FEATURES GRID
   ===================================================== */
.partners-grid {
    display: grid;
    gap: var(--space-md);
}

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

.partner-item {
    padding: var(--space-xl) var(--space-lg);
    background: var(--cream);
    border: 1px solid var(--cream-dark);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.partner-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--navy);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
}

.partner-item:hover {
    background: var(--white);
    box-shadow: 0 10px 40px rgba(10, 22, 40, 0.08);
    transform: translateY(-4px);
}

.partner-item:hover::before {
    transform: translateX(0);
}

.partner-icon {
    width: 48px;
    height: 48px;
    background: var(--navy);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--space-md);
}

.partner-icon svg {
    width: 24px;
    height: 24px;
    stroke: var(--white);
}

.partner-item h4 {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--navy);
    margin-bottom: var(--space-sm);
}

.partner-item p {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* =====================================================
   STATS BAR
   ===================================================== */
.stats-bar {
    background: var(--navy);
    padding: var(--space-xl) 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-lg);
    text-align: center;
}

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

.stat-item {
    color: var(--white);
}

.stat-number {
    font-family: var(--font-serif);
    font-size: 2.5rem;
    font-weight: 400;
    color: var(--gold);
    margin-bottom: var(--space-xs);
}

.stat-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    opacity: 0.7;
}

/* =====================================================
   IMAGE GRID
   ===================================================== */
.image-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-sm);
}

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

.image-grid-item {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1;
}

.image-grid-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.image-grid-item:hover img {
    transform: scale(1.1);
}

/* =====================================================
   CTA BLOCK
   ===================================================== */
.section-cta-block {
    background: var(--red);
    text-align: center;
    padding: var(--space-2xl) 0;
    position: relative;
    overflow: hidden;
}

.section-cta-block::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -10%;
    width: 40%;
    height: 200%;
    background: rgba(255, 255, 255, 0.03);
    transform: rotate(15deg);
}

.section-cta-block::after {
    content: '';
    position: absolute;
    bottom: -50%;
    right: -10%;
    width: 40%;
    height: 200%;
    background: rgba(0, 0, 0, 0.05);
    transform: rotate(-15deg);
}

.cta-content {
    position: relative;
    z-index: 1;
}

.section-cta-block .cta-content h2 {
    font-family: var(--font-serif);
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 400;
    color: var(--white);
    margin-bottom: var(--space-sm);
}

.section-cta-block .cta-content p {
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: var(--space-lg);
    font-size: 1.1rem;
}

/* =====================================================
   FOOTER
   ===================================================== */
.footer {
    background: var(--navy);
    color: var(--white);
    padding: var(--space-2xl) 0 var(--space-lg);
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--red), var(--gold), var(--red));
}

.footer-grid {
    display: grid;
    gap: var(--space-xl);
    margin-bottom: var(--space-xl);
}

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

.footer-brand .logo-mark {
    background: rgba(255, 255, 255, 0.1);
    margin-bottom: var(--space-md);
    display: inline-block;
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.6);
    max-width: 280px;
    font-size: 0.9rem;
    line-height: 1.7;
}

.footer-links h5,
.footer-contact h5 {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    margin-bottom: var(--space-md);
    color: var(--gold);
}

.footer-links a {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    padding: var(--space-xs) 0;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.footer-links a:hover {
    color: var(--white);
    padding-left: 8px;
}

.footer-contact p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    margin-bottom: var(--space-xs);
}

.footer-bottom {
    padding-top: var(--space-lg);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--space-sm);
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.85rem;
}

.footer-credit {
    font-size: 0.8rem;
}

.footer-credit a {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    transition: color 0.2s ease;
    position: relative;
}

.footer-credit a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--gold);
    transition: width 0.3s ease;
}

.footer-credit a:hover {
    color: var(--gold);
}

.footer-credit a:hover::after {
    width: 100%;
}

/* =====================================================
   PAGE HEADER
   ===================================================== */
.page-header {
    padding: calc(var(--space-3xl) + 60px) 0 var(--space-xl);
    background: var(--cream);
    position: relative;
}

.page-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 40%;
    height: 100%;
    background: 
        linear-gradient(135deg, transparent 25%, var(--cream-dark) 25%, var(--cream-dark) 50%, transparent 50%, transparent 75%, var(--cream-dark) 75%);
    background-size: 40px 40px;
    opacity: 0.3;
}

.page-header-content {
    max-width: 640px;
    position: relative;
    z-index: 1;
}

.page-header h1 {
    font-family: var(--font-serif);
    font-size: clamp(2.25rem, 5vw, 3.5rem);
    font-weight: 400;
    color: var(--navy);
    margin-bottom: var(--space-sm);
}

.page-header p {
    color: var(--text-light);
    font-size: 1.125rem;
}

/* =====================================================
   CONTACT FORM
   ===================================================== */
.contact-grid {
    display: grid;
    gap: var(--space-2xl);
}

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

.contact-form {
    background: var(--white);
    padding: var(--space-xl);
    border: 1px solid var(--cream-dark);
}

.form-group {
    margin-bottom: var(--space-md);
}

.form-group label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: var(--space-xs);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 1rem;
    font-family: var(--font-sans);
    font-size: 1rem;
    border: 2px solid var(--cream-dark);
    background: var(--cream);
    transition: all 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--navy);
    background: var(--white);
}

.form-group textarea {
    min-height: 150px;
    resize: vertical;
}

.contact-info h3 {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--navy);
    margin-bottom: var(--space-md);
}

.contact-info > p {
    color: var(--text-light);
    margin-bottom: var(--space-lg);
    line-height: 1.7;
}

.contact-details {
    list-style: none;
}

.contact-details li {
    padding: var(--space-sm) 0;
    border-bottom: 1px solid var(--cream-dark);
    color: var(--text);
    font-size: 0.95rem;
}

.contact-details li strong {
    color: var(--navy);
}

/* =====================================================
   ANIMATIONS
   ===================================================== */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.hero-content > * {
    animation: fadeUp 0.7s ease-out forwards;
    opacity: 0;
}

.hero-label { animation-delay: 0.1s; }
.hero-title { animation-delay: 0.2s; }
.hero-text { animation-delay: 0.35s; }
.hero-actions { animation-delay: 0.5s; }

.hero-image {
    animation: fadeIn 1s ease-out 0.4s forwards;
    opacity: 0;
}

/* Scroll animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.7s ease-out;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 768px) {
    .hero {
        min-height: auto;
        padding: calc(var(--space-3xl) + 60px) 0 var(--space-2xl);
    }
    
    .section {
        padding: var(--space-2xl) 0;
    }
    
    .service-item {
        grid-template-columns: 60px 1fr;
        padding: var(--space-lg);
    }
    
    .service-number {
        font-size: 1.75rem;
    }
}

/* Mobile menu */
.nav.mobile-open {
    display: flex;
    position: fixed;
    top: 70px;
    left: var(--space-md);
    right: var(--space-md);
    flex-direction: column;
    background: var(--white);
    padding: var(--space-sm);
    border: 1px solid var(--cream-dark);
    box-shadow: 0 10px 40px rgba(10, 22, 40, 0.1);
    gap: 0;
}

.nav.mobile-open a {
    padding: var(--space-sm) var(--space-md);
    border-bottom: 1px solid var(--cream-dark);
}

.nav.mobile-open a:last-child {
    border-bottom: none;
}

.nav.mobile-open a::after {
    display: none;
}
