/* ==========================================================================
   Delicia Loh - ACE Your Game
   Color Palette: Slate Blue (Right Column)
   ========================================================================== */

:root {
    /* Deep Blue Color Palette */
    --color-lead: #4A6D8C;
    --color-lead-dark: #3A5A7A;
    --color-lead-light: #6A8FAA;
    --color-accent: #D0DCE4;
    --color-accent-light: #E8EEF2;
    --color-background: #B8C9D4;
    --color-background-light: #E8EEF2;
    --color-text: #484852;
    --color-text-light: #6A6A72;
    --color-white: #F5F2ED;
    --color-pure-white: #FFFFFF;
    --color-dark: #3A3A42;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 6rem;

    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-full: 50%;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* ==========================================================================
   Reset & Base Styles
   ========================================================================== */

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

html {
    scroll-behavior: smooth;
    margin: 0;
    padding: 0;
}

body {
    overflow-x: hidden;
    margin: 0;
    padding: 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--color-text);
    line-height: 1.6;
    background-color: var(--color-white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-weight: 600;
    line-height: 1.2;
    color: var(--color-dark);
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-fast);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul {
    list-style: none;
}

/* ==========================================================================
   Layout
   ========================================================================== */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

section {
    padding: var(--spacing-xl) 0;
}

.section-label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--color-lead);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: var(--spacing-sm);
    font-family: 'Inter', sans-serif;
    text-align: left;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3.5rem);
    color: var(--color-dark);
    margin-bottom: 1.5rem;
    text-align: left;
}

.section-title span {
    color: var(--color-lead);
}

.section-intro {
    font-size: 1.1rem;
    color: var(--color-text-light);
    max-width: none;
    line-height: 1.8;
    margin-bottom: var(--spacing-lg);
}

/* ==========================================================================
   WhatsApp Float Button
   ========================================================================== */

.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: #25D366;
    color: var(--color-pure-white);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(37, 211, 102, 0.5);
}

/* ==========================================================================
   Navigation
   ========================================================================== */

header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    transition: all var(--transition-normal);
    background: transparent;
    margin: 0;
    padding: 0;
}

/* Prevent any container padding/margin from creating gaps inside the header */
#header .container {
    padding-top: 0;
    padding-bottom: 0;
    margin-top: 0;
    margin-bottom: 0;
}

header.scrolled,
header.solid {
    background: rgba(250, 248, 245, 0.98);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--color-pure-white);
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
    transition: color var(--transition-fast), text-shadow var(--transition-fast);
}

header.scrolled .logo,
header.solid .logo {
    color: var(--color-dark);
    text-shadow: none;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
}

.nav-links a {
    font-size: 0.95rem;
    font-weight: 400;
    color: var(--color-pure-white);
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
    letter-spacing: 0.5px;
    position: relative;
    padding: 0.5rem 0;
}

header.scrolled .nav-links a,
header.solid .nav-links a {
    color: var(--color-text);
    text-shadow: none;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-lead);
    transition: width var(--transition-normal);
}

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

.nav-links a:hover,
.nav-links a.active {
    color: var(--color-pure-white);
    text-shadow: 0 1px 6px rgba(0, 0, 0, 0.7);
}

header.scrolled .nav-links a:hover,
header.scrolled .nav-links a.active,
header.solid .nav-links a:hover,
header.solid .nav-links a.active {
    color: var(--color-lead);
    text-shadow: none;
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 101;
}

.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--color-pure-white);
    margin: 5px 0;
    transition: all var(--transition-normal);
}

header.scrolled .mobile-menu-btn span,
header.solid .mobile-menu-btn span {
    background: var(--color-text);
}

/* Mobile Menu */
.mobile-menu {
    display: none;
    position: absolute;
    top: 80px;
    left: 0;
    right: 0;
    background: var(--color-pure-white);
    padding: var(--spacing-md);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.mobile-menu.active {
    display: block;
}

.mobile-menu ul {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.mobile-menu a {
    display: block;
    padding: 0.75rem 0;
    color: var(--color-text);
    font-size: 1rem;
    border-bottom: 1px solid var(--color-accent);
}

.mobile-menu a:hover {
    color: var(--color-lead);
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    font-size: 0.95rem;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    letter-spacing: 0.5px;
    border: none;
    cursor: pointer;
    transition: all var(--transition-normal);
    text-align: center;
}

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

.btn-primary:hover {
    background: var(--color-lead-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(181, 169, 154, 0.4);
}

.btn-secondary {
    border: 1px solid var(--color-pure-white);
    color: var(--color-pure-white);
    background: transparent;
}

.btn-secondary:hover {
    background: var(--color-pure-white);
    color: var(--color-text);
}

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

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

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

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

.btn-group {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.hero {
    min-height: 100vh;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('../images/web panel-enhance.jpg');
    background-size: cover;
    background-position: center top;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    position: relative;
}

.hero-content {
    max-width: 800px;
    color: var(--color-pure-white);
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 1.5rem;
    line-height: 1.1;
    color: var(--color-pure-white);
}

.hero p {
    font-size: 1.15rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    max-width: 600px;
    line-height: 1.8;
}

@media (max-width: 768px) {
    .hero {
        background-attachment: scroll;
        background-position: center center;
        align-items: flex-start;
        padding-top: 100px;
    }

    .hero-content {
        background: rgba(0, 0, 0, 0.7);
        padding: 2rem;
        border-radius: var(--radius-md);
        margin: 1rem;
    }

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

    .hero p {
        font-size: 1rem;
        margin-bottom: 1.5rem;
        line-height: 1.6;
    }

    .hero-services.page-hero {
        background-position: 42% 45% !important;
    }
}

/* Hero Split Layout (text left, image right) */
.hero-split {
    display: grid;
    grid-template-columns: 2fr 3fr;
    min-height: 100vh;
    width: 100%;
}

.hero-split-text {
    display: flex;
    align-items: center;
    padding: 6rem 3rem 3rem;
}

.hero-split-image {
    padding: 5rem 2rem 0;
    overflow: hidden;
}

.hero-split-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: bottom center;
    border-radius: 12px;
}

@media (max-width: 1024px) {
    .hero-split {
        display: block;
        position: relative;
        min-height: 100vh;
        overflow: hidden;
    }

    .hero-split-image {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        padding: 0;
    }

    .hero-split-image::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 120px;
        background: linear-gradient(to bottom, rgba(0,0,0,0.6), transparent);
        z-index: 1;
    }

    .hero-split-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: 50% center;
        border-radius: 0;
    }

    .hero-split-text {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        padding: 2rem 2rem 9rem;
        background: linear-gradient(transparent, rgba(0,0,0,0.6) 25%, rgba(0,0,0,0.85));
        z-index: 1;
    }

    .hero-split .hero-content {
        background: transparent;
        border-radius: 0;
        margin: 0;
    }
}

@media (max-width: 768px) {
    .hero-split-text {
        padding: 0.75rem 1.5rem 9rem;
        background: linear-gradient(transparent, rgba(0,0,0,0.5) 15%, rgba(0,0,0,0.85) 40%);
    }

    .hero-split-text .hero-content h1 {
        font-size: 1.6rem;
        margin-bottom: 0.5rem;
    }

    .hero-split-text .hero-content p {
        font-size: 0.8rem;
        line-height: 1.5;
        margin-bottom: 0.75rem;
    }

    .hero-split-text .hero-content .btn-group {
        flex-direction: row;
        flex-wrap: nowrap;
        gap: 0.75rem;
    }

    .hero-split-text .hero-content .btn-group .btn {
        width: auto;
        padding: 0.6rem 1.1rem;
        font-size: 0.8rem;
    }
}

/* Hero Home - Full-width background on desktop, stacked on mobile */
.hero-home {
    position: relative;
    min-height: 100vh;
    background: url('../images/hero-home-panel.jpg') 50% 38% / cover no-repeat;
    display: flex;
    align-items: center;
    padding: 0;
    margin: 0;
}

.hero-home::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to right, rgba(30,30,36,0.95) 0%, rgba(40,40,48,0.9) 25%, rgba(0,0,0,0.55) 45%, rgba(0,0,0,0.15) 65%, transparent 80%);
}

.hero-home-mobile-img {
    display: none;
}

.hero-home-text {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
    width: 100%;
}

.hero-home-text .hero-content {
    color: var(--color-pure-white);
    max-width: 520px;
}

.hero-home-text .hero-content h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 1.5rem;
    line-height: 1.1;
    color: var(--color-pure-white);
}

.hero-home-text .hero-content p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.92;
    line-height: 1.8;
}

@media (max-width: 1024px) {
    .hero-home {
        min-height: 100vh;
        min-height: 100svh;
        background: none;
        background-color: #3A3A42;
        position: relative;
        display: block;
        overflow: hidden;
        padding: 0;
        margin: 0;
    }

    .hero-home::after {
        display: none;
    }

    .hero-home-mobile-img {
        display: block;
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        overflow: hidden;
    }

    .hero-home-mobile-img img {
        width: 100%;
        height: 100%;
        min-height: 100%;
        object-fit: cover;
        object-position: 50% 30%;
        display: block;
        transform: scale(1.1);
        transform-origin: 50% 30%;
    }

    .hero-home-text {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        padding: 2.5rem 2rem 3rem;
        background: linear-gradient(transparent, rgba(0,0,0,0.6) 25%, rgba(0,0,0,0.88));
        z-index: 1;
    }

    .hero-home-text .hero-content {
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    .hero-home {
        padding: 0;
        margin: 0;
    }

    .hero-home-text {
        padding: 0.75rem 1.5rem 1.5rem;
        background: linear-gradient(transparent, rgba(0,0,0,0.55) 20%, rgba(0,0,0,0.9) 50%);
    }

    .hero-home-text .hero-content h1 {
        font-size: 1.3rem;
        margin-bottom: 0.4rem;
    }

    .hero-home-text .hero-content p {
        font-size: 0.75rem;
        line-height: 1.5;
        margin-bottom: 0.75rem;
    }

    .hero-home-text .hero-content .btn-group {
        flex-direction: row;
        gap: 0.6rem;
    }

    .hero-home-text .hero-content .btn-group .btn {
        padding: 0.5rem 1rem;
        font-size: 0.75rem;
    }
}

/* Page Hero (smaller for inner pages) */
.page-hero {
    padding: 12rem 0 6rem;
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('../images/web panel-enhance.jpg');
    background-size: cover;
    background-position: center;
    color: var(--color-pure-white);
    text-align: center;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.page-hero h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--color-pure-white);
    margin-bottom: 1rem;
    text-shadow: 0 2px 8px rgba(0,0,0,0.7);
}

.page-hero p {
    font-size: 1.1rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
    text-shadow: 0 1px 6px rgba(0,0,0,0.7);
}

/* ==========================================================================
   Cards
   ========================================================================== */

.card {
    background: var(--color-pure-white);
    border: 1px solid var(--color-accent);
    border-radius: var(--radius-md);
    padding: var(--spacing-md);
    transition: all var(--transition-normal);
}

.card:hover {
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    transform: translateY(-5px);
}

.card-icon {
    width: 50px;
    height: 50px;
    background: var(--color-lead);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

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

.card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

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

/* ==========================================================================
   ACE Philosophy
   ========================================================================== */

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


.ace-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-md);
    margin-top: var(--spacing-lg);
}

.ace-card {
    background: var(--color-pure-white);
    padding: 2.5rem;
    border-radius: var(--radius-md);
    text-align: center;
    transition: all var(--transition-normal);
    border: 1px solid var(--color-accent);
}

.ace-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.ace-letter {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 4rem;
    font-weight: 700;
    color: var(--color-lead);
    margin-bottom: 1rem;
}

.ace-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

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

/* ==========================================================================
   Expertise & Services Grid
   ========================================================================== */

.expertise-grid,
.services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

/* Homepage 3-column services grid - always horizontal */
.services-home-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    max-width: 100%;
}

.services-home-grid .card {
    padding: 1.25rem;
}

.services-home-grid .card h3 {
    font-size: 1rem;
}

.services-home-grid .card p {
    font-size: 0.85rem;
    line-height: 1.5;
}

.services-home-grid .card-icon {
    width: 40px;
    height: 40px;
    margin-bottom: 1rem;
}

.services-home-grid .card-icon svg {
    width: 20px;
    height: 20px;
}

.unique-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

/* ==========================================================================
   Testimonials
   ========================================================================== */

.testimonials-section {
    background: var(--color-pure-white);
}

.testimonials-section .section-label {
    color: var(--color-lead);
    font-weight: 600;
}

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

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.testimonial-card {
    background: var(--color-accent-light);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    border: 1px solid var(--color-accent);
}

.testimonial-card blockquote {
    font-size: 1.05rem;
    color: var(--color-text);
    line-height: 1.8;
    margin-bottom: 1rem;
    font-style: italic;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
    color: var(--color-text-light);
}

.testimonial-author img {
    width: 20px;
    height: auto;
    border-radius: 2px;
}

/* ==========================================================================
   Gallery
   ========================================================================== */

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-md);
    aspect-ratio: 4/3;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

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

.gallery-item .overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition-normal);
}

.gallery-item:hover .overlay {
    opacity: 1;
}

.gallery-item .overlay svg {
    width: 40px;
    height: 40px;
    stroke: var(--color-pure-white);
}

/* Gallery Lightbox */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: var(--spacing-md);
}

.lightbox.active {
    display: flex;
}

.lightbox img {
    max-width: 90%;
    max-height: 90vh;
    object-fit: contain;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    color: var(--color-pure-white);
    font-size: 2rem;
    cursor: pointer;
    padding: 0.5rem;
}

/* ==========================================================================
   Contact Form
   ========================================================================== */

.contact-section {
    background: var(--color-pure-white);
}

.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
    overflow: hidden;
}

.contact-layout > * {
    min-width: 0;
}

.contact-info h2 {
    margin-bottom: 1.5rem;
}

.contact-info > p {
    font-size: 1.1rem;
    color: var(--color-text-light);
    margin-bottom: var(--spacing-md);
    line-height: 1.8;
}

.contact-details {
    margin-top: var(--spacing-md);
}

.contact-item {
    margin-bottom: 1.5rem;
}

.contact-item h3 {
    font-size: 1rem;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.contact-item a {
    color: var(--color-text-light);
}

.contact-item a:hover {
    color: var(--color-lead);
}

/* Form Styles */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-size: 0.95rem;
    color: var(--color-dark);
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 1rem;
    border: 1px solid var(--color-accent);
    border-radius: var(--radius-sm);
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    color: var(--color-text);
    transition: border-color var(--transition-fast);
    background: var(--color-pure-white);
}

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

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

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--color-text-light);
}

/* Form Messages */
.form-message {
    padding: 1rem;
    border-radius: var(--radius-sm);
    margin-bottom: 1.5rem;
}

.form-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.form-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* ==========================================================================
   Resources Page
   ========================================================================== */

.resources-section {
    background: var(--color-pure-white);
}

.resources-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.resource-card {
    display: flex;
    gap: 1.5rem;
    background: var(--color-white);
    border: 1px solid var(--color-accent);
    border-radius: var(--radius-md);
    padding: 2rem;
    transition: all var(--transition-normal);
}

.resource-card:hover {
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    transform: translateY(-3px);
}

.resource-icon {
    width: 60px;
    height: 60px;
    min-width: 60px;
    background: var(--color-lead);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
}

.resource-icon svg {
    width: 28px;
    height: 28px;
    stroke: var(--color-pure-white);
}

.resource-content h3 {
    font-size: 1.35rem;
    margin-bottom: 0.75rem;
    color: var(--color-dark);
}

.resource-content > p {
    color: var(--color-text-light);
    line-height: 1.7;
    margin-bottom: 1rem;
}

.resource-highlights {
    list-style: none;
    margin-bottom: 1.5rem;
}

.resource-highlights li {
    position: relative;
    padding-left: 1.5rem;
    color: var(--color-text);
    font-size: 0.9rem;
    margin-bottom: 0.4rem;
}

.resource-highlights li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--color-lead);
    font-weight: bold;
}

.resource-card .btn {
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
}

@media (max-width: 1024px) {
    .resources-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .resource-card {
        flex-direction: column;
        text-align: center;
    }

    .resource-icon {
        margin: 0 auto;
    }

    .resource-highlights {
        display: inline-block;
        text-align: left;
    }

    .resource-card .btn {
        width: 100%;
    }
}

/* ==========================================================================
   Newsletter Section
   ========================================================================== */

.newsletter-section {
    background: var(--color-lead);
    padding: 4rem 0;
}

.newsletter-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.newsletter-text h3 {
    font-size: 2rem;
    color: var(--color-pure-white);
    margin-bottom: 0.75rem;
}

.newsletter-text p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.05rem;
    line-height: 1.7;
}

.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.newsletter-input-group {
    display: flex;
    gap: 0.75rem;
}

.newsletter-input-group input {
    flex: 1;
    padding: 1rem 1.25rem;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-family: 'Inter', sans-serif;
}

.newsletter-input-group input:focus {
    outline: 2px solid var(--color-accent);
}

.newsletter-input-group .btn {
    white-space: nowrap;
    background: var(--color-dark);
}

.newsletter-input-group .btn:hover {
    background: var(--color-text);
}

.newsletter-disclaimer {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
}

.newsletter-message {
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.newsletter-message.success {
    background: rgba(255, 255, 255, 0.2);
    color: var(--color-pure-white);
}

.newsletter-message.error {
    background: rgba(220, 53, 69, 0.3);
    color: var(--color-pure-white);
}

@media (max-width: 768px) {
    .newsletter-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .newsletter-input-group {
        flex-direction: column;
    }

    .newsletter-input-group .btn {
        width: 100%;
    }
}

/* ==========================================================================
   Footer
   ========================================================================== */

footer {
    background: var(--color-background-light);
    padding: var(--spacing-lg) 0 var(--spacing-md);
    border-top: 1px solid var(--color-accent);
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
}

.footer-brand h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.footer-brand p {
    color: var(--color-text-light);
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: var(--color-lead);
    color: var(--color-pure-white);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-normal);
}

.social-links a:hover {
    background: var(--color-lead-dark);
    transform: translateY(-3px);
}

.footer-nav h4,
.footer-connect h4 {
    font-size: 1.1rem;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    margin-bottom: 1.5rem;
}

.footer-nav li {
    margin-bottom: 0.75rem;
}

.footer-nav a,
.footer-connect a {
    color: var(--color-text-light);
}

.footer-nav a:hover,
.footer-connect a:hover {
    color: var(--color-lead);
}

.footer-connect p {
    margin-bottom: 0.75rem;
}

.footer-bottom {
    padding-top: var(--spacing-md);
    border-top: 1px solid var(--color-accent);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--color-text-light);
    font-size: 0.9rem;
}

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

.footer-bottom a:hover {
    color: var(--color-lead-dark);
}

/* ==========================================================================
   About Page Specific
   ========================================================================== */

.about-content-section {
    background: var(--color-pure-white);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: var(--spacing-lg);
    align-items: start;
}

.about-image img {
    width: 100%;
    max-width: 400px;
    border-radius: var(--radius-md);
    background: var(--color-background-light);
}

.about-text p {
    font-size: 1.1rem;
    color: var(--color-text-light);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.about-text p.highlight {
    font-weight: 500;
    color: var(--color-text);
}

/* Credentials */
.credentials-section {
    background: var(--color-background-light);
}

.credentials-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.credential-card {
    background: var(--color-pure-white);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    border: 1px solid var(--color-accent);
}

.credential-card h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--color-lead);
    font-weight: 700;
}

.credential-card ul {
    list-style: disc;
    margin-left: 1.25rem;
}

.credential-card li {
    color: var(--color-text-light);
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

/* ==========================================================================
   Services Page Specific
   ========================================================================== */

.service-detail {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
    align-items: center;
    padding: var(--spacing-lg) 0;
    border-bottom: 1px solid var(--color-accent);
}

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

.service-detail.reverse {
    direction: rtl;
}

.service-detail.reverse > * {
    direction: ltr;
}

.service-detail-image img {
    width: 100%;
    border-radius: var(--radius-md);
}

.service-detail-content h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.service-detail-content p {
    color: var(--color-text-light);
    margin-bottom: 1rem;
    line-height: 1.8;
}

.service-detail-content ul {
    margin: 1.5rem 0;
}

.service-detail-content li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    color: var(--color-text-light);
}

.service-detail-content li svg {
    width: 20px;
    height: 20px;
    stroke: var(--color-lead);
    flex-shrink: 0;
    margin-top: 2px;
}

/* ==========================================================================
   CTA Section
   ========================================================================== */

.cta-section {
    background: var(--color-lead);
    padding: var(--spacing-lg) 0;
    text-align: center;
}

.cta-section h2 {
    color: var(--color-pure-white);
    margin-bottom: 1rem;
}

.cta-section p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.1rem;
    margin-bottom: var(--spacing-md);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 1024px) {
    .hero {
        background-attachment: scroll;
    }

    .contact-layout,
    .service-detail {
        grid-template-columns: 1fr;
    }

    .service-detail.reverse {
        direction: ltr;
    }

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

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

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    /* On narrow screens only logo + hamburger are visible — reduce container side padding
       and explicitly zero any vertical spacing so the header sits flush over the hero */
    #header .container {
        padding: 0 1rem;
        margin: 0;
    }

    .about-grid,
    .ace-grid,
    .expertise-grid,
    .services-grid,
    .credentials-grid,
    .gallery-grid,
    .unique-grid {
        grid-template-columns: 1fr;
    }

    /* Keep homepage services as 3 columns on mobile */
    .services-home-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.5rem;
    }

    .services-home-grid .card {
        padding: 0.75rem;
    }

    .services-home-grid .card h3 {
        font-size: 0.75rem;
        margin-bottom: 0.5rem;
    }

    .services-home-grid .card p {
        font-size: 0.65rem;
        line-height: 1.4;
        display: none;
    }

    .services-home-grid .card-icon {
        width: 32px;
        height: 32px;
        margin-bottom: 0.5rem;
    }

    .services-home-grid .card-icon svg {
        width: 16px;
        height: 16px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    section {
        padding: var(--spacing-lg) 0;
    }

    .btn-group {
        flex-direction: column;
    }

    .btn {
        text-align: center;
        width: 100%;
    }

    .page-hero {
        padding: 10rem 0 4rem;
        min-height: 100vh;
    }

    .page-hero.hero-person-left {
        background-position: left 15% !important;
    }

    .page-hero.hero-person-center-left {
        background-position: 33% calc(25% + 32px) !important;
        padding-top: 23rem;
    }

    .whatsapp-float {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }

    /* Reinforce: header and its container must not add any vertical space */
    #header {
        margin: 0;
        padding: 0;
    }

    #header .container {
        padding: 0 0.75rem;
        margin: 0;
    }

    /* Ensure hero-home has zero gap at very narrow widths */
    .hero-home {
        padding: 0;
        margin: 0;
    }

    .hero-home-mobile-img {
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .page-hero.hero-person-center-left {
        padding-top: 14rem;
        background-position: 33% 28% !important;
    }
}
