:root {
    --brand-color: #B22B07;
    --brand-dark: #6A1A04;
    --bg-light: #FDFDFD;
    --text-dark: #1A1A1A;
    --text-muted: #5A5A5A; /* Improved contrast from #6C6C6C for WCAG AA compliance */
    --card-bg: #FFFFFF;
    --card-border: #F0F0F0;
}

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

body {
    background-color: var(--bg-light);
    color: var(--text-dark);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px 20px;
    position: relative;
}

/* Fixed Background Container */
.bg-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -1;
    pointer-events: none;
}

/* Dynamic Motion Backgrounds */
.bg-blob {
    position: absolute;
    width: 450px;
    height: 450px;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.5;
}

.blob-top-left {
    top: -100px;
    left: -100px;
    background: rgba(178, 43, 7, 0.25);
    animation: organicDrift 10s ease-in-out infinite alternate;
}

.blob-bottom-right {
    top: auto;
    left: auto;
    bottom: -100px;
    right: -100px;
    background: rgba(224, 68, 27, 0.3);
    animation: organicDrift 12s ease-in-out infinite alternate-reverse;
}

/* Cursor Follower Blob */
.blob-cursor {
    top: 0;
    left: 0;
    width: 400px;
    height: 400px;
    background: rgba(224, 68, 27, 0.25);
    will-change: transform;
    opacity: 0.3; 
}

@keyframes organicDrift {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(40px, -30px) scale(1.15); }
    100% { transform: translate(-20px, 40px) scale(0.95); }
}

/* Layout Container */
.app-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    grid-template-rows: auto 1fr; 
    column-gap: 70px;
    width: 100%;
    max-width: 1050px;
}

/* Staggered Load Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-panel {
    display: flex;
    flex-direction: column;
    gap: 36px; 
    align-items: flex-start;
    height: 100%;
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.left-panel {
    grid-column: 1;
    grid-row: 1 / span 2;
    display: flex;
    flex-direction: column;
    gap: 55px;
    height: 100%;
}

.services-panel {
    grid-column: 2;
    grid-row: 1 / span 2;
    width: 100%;
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s forwards;
}

/* Hero Panel Elements */
.brand-header {
    display: flex;
    align-items: center;
    gap: 20px;
}

.logo {
    width: 80px;
    height: 80px;
    filter: drop-shadow(0 8px 20px rgba(178, 43, 7, 0.15));
    flex-shrink: 0;
}

.brand-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--brand-dark);
    margin-bottom: 2px;
    letter-spacing: -0.5px;
}

.brand-tagline {
    font-size: 0.95rem;
    color: var(--text-muted);
    font-weight: 500;
    font-style: italic;
}

.hero-middle {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: relative; 
    width: 100%;
    flex: 1;
}

/* Arrow doodle pointing to QR Code card */
.arrow-doodle {
    position: absolute;
    left: -90px;
    top: -55px; /* Shunted up next to the logo and tagline */
    width: 72px; 
    height: auto;
    transform: rotate(-5deg); /* Pointing down-right directly at the QR card */
    animation: colorPulseDoodle 5s ease-in-out infinite;
    z-index: 1;
    pointer-events: none; 
}

@keyframes colorPulseDoodle {
    0%, 100% { opacity: 0.85; filter: brightness(1) contrast(1); }
    50% { opacity: 1; filter: brightness(1.2) contrast(1.1); }
}

.button-lead {
    font-size: 1.05rem;
    color: var(--text-dark);
    font-weight: 100;
    line-height: 1.6;
    margin-bottom: 10px;
    max-width: 420px;
    position: relative;
    z-index: 2;
}

.text-link {
    color: var(--brand-color);
    font-weight: 700;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.text-link:hover {
    text-decoration: underline;
    opacity: 0.85;
}

.brand-text {
    color: var(--brand-color);
    font-weight: 700;
}

/* RESPONSIVE LAYOUT SWITCHING */

/* Desktop Layout */
.desktop-layout {
    display: flex;
    gap: 28px;
    align-items: stretch;
    margin-top: 10px;
    width: 100%;
    flex: 1;
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.15s forwards;
    position: relative;
    z-index: 2;
}

.qr-column-desktop {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    width: 180px;
    flex-shrink: 0;
}

.qr-card-desktop {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: rgba(255, 255, 255, 0.65);
    border: 1px solid rgba(178, 43, 7, 0.18);
    border-radius: 20px;
    padding: 16px 16px 20px 16px; /* Compact padding */
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    width: 100%;
    box-shadow: 0 10px 30px rgba(178, 43, 7, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.qr-card-desktop:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(178, 43, 7, 0.08);
    border-color: rgba(178, 43, 7, 0.18);
}

/* Animating Text Gradient */
.qr-gradient-title {
    background: linear-gradient(90deg, #B22B07, #E0441B, #B22B07);
    background-size: 200% 100%;
    animation: slideGradient 3s linear infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 0.88rem;
    font-weight: 800;
    margin-bottom: 14px;
    display: inline-block;
    letter-spacing: -0.2px;
}

.qr-code-img-desktop {
    width: 130px;
    height: 130px;
    display: block;
    margin: 8px 0 16px 0;
}

.qr-subtext {
    font-size: 0.68rem;
    color: var(--text-muted);
    font-weight: 600;
    line-height: 1.3;
    margin-top: 4px;
}

.location-group-desktop {
    display: flex;
    flex-direction: column;
    align-items: flex-start; /* Left-aligned below Follow Us */
    margin-top: auto;
    width: 100%;
    padding-top: 12px;
    padding-bottom: 15px;
    border-top: 1px solid rgba(178, 43, 7, 0.14);
}

.location-group-desktop .location {
    font-size: 0.78rem;
    color: var(--text-dark); /* Dark bold text for location name */
    font-weight: 800;
    margin-bottom: 3px;
    letter-spacing: 0;
}

.location-group-desktop .footer-text {
    font-size: 0.66rem;
    color: var(--text-muted);
    line-height: 1.3;
}

.info-column-desktop {
    display: flex;
    flex-direction: column;
    gap: 24px;
    flex-grow: 1; /* Stretch to fill remaining row space */
}

/* Mobile Layout Base (Hidden on Desktop) */
.mobile-layout {
    display: none;
}

.mobile-connect-footer {
    display: none;
}

/* Shared Connect Blocks & Links styling */
.contact-block,
.social-block,
.mail-block {
    display: flex;
    flex-direction: column;
}

.caveat-accent {
    font-family: 'Caveat', cursive;
    font-weight: 700;
    font-size: 1.4rem;
    color: var(--brand-color);
    text-transform: lowercase;
}

.say-hello,
.follow-us,
.mail-us {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 9px;
}

.say-hello svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
    flex-shrink: 0;
}

.follow-us svg {
    width: 22px;
    height: 22px;
    fill: currentColor;
    flex-shrink: 0;
}

.mail-us svg {
    width: 22px;
    height: 22px;
    display: block;
    fill: currentColor;
    flex-shrink: 0;
}

.mail-us .caveat-accent {
    white-space: nowrap;
}

.phone-stack {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.phone-link {
    font-size: 1rem;
    color: var(--text-dark);
    font-weight: 800;
    text-decoration: none;
    transition: color 0.2s ease;
    white-space: nowrap;
}

.phone-link:hover {
    color: var(--brand-color);
}

.mail-link {
    font-size: 0.92rem;
    color: var(--text-dark);
    font-weight: 700;
    text-decoration: none;
    transition: color 0.2s ease;
    white-space: nowrap;
}

.mail-link:hover {
    color: var(--brand-color);
}

.social-links {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    color: var(--text-dark);
    background: transparent;
    border: 1px solid rgba(178, 43, 7, 0.18);
    text-decoration: none;
    transition: color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.social-link:hover {
    color: var(--brand-color);
    border-color: rgba(178, 43, 7, 0.35);
    transform: translateY(-2px);
}

.social-link svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* Direct APK Download Button */
.download-btn {
    background: linear-gradient(90deg, #B22B07, #E0441B, #B22B07);
    background-size: 200% 100%;
    animation: slideGradient 3s linear infinite; 
    color: #FFFFFF;
    text-decoration: none;
    padding: 16px 36px;
    border-radius: 14px;
    font-size: 1.05rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 10px 25px rgba(178, 43, 7, 0.22);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    width: 100%;
    max-width: 340px;
    justify-content: center;
    position: relative;
    z-index: 2;
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(178, 43, 7, 0.32);
}

.download-btn:active {
    transform: translateY(0);
}

.download-btn svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    fill: none;
}

.qr-download-btn {
    background: rgba(255, 255, 255, 0.45);
    animation: none;
    color: var(--text-dark);
    border: 1px solid rgba(178, 43, 7, 0.18);
    max-width: none;
    padding: 13px 16px;
    border-radius: 14px;
    font-size: 0.9rem;
    box-shadow: 0 8px 22px rgba(178, 43, 7, 0.04);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.qr-download-btn:hover {
    color: var(--brand-color);
    border-color: rgba(178, 43, 7, 0.35);
    box-shadow: 0 12px 30px rgba(178, 43, 7, 0.08);
}

.qr-download-btn svg {
    width: 18px;
    height: 18px;
}

@keyframes slideGradient {
    0% { background-position: 200% 0; }
    100% { background-position: 0 0; }
}

/* Services Header */
.services-header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    width: 100%;
}

.services-heading {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-dark);
    position: relative;
    padding-left: 14px;
}

.services-heading::before {
    content: '';
    position: absolute;
    left: 0;
    top: 3px;
    bottom: 3px;
    width: 4px;
    background: linear-gradient(to bottom, #B22B07, #E0441B);
    border-radius: 2px;
}

.services-subtext {
    text-align: right;
    padding-right: 4px;
    font-family: 'Caveat', cursive;
    font-weight: 700;
    font-size: 1.4rem;
    color: var(--brand-color);
    text-transform: lowercase;
}

/* Services Grid & Cards */
.services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.service-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    padding: 24px;
    border-radius: 16px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.service-card:hover {
    transform: translateY(-4px); /* Elevated translation for depth */
    box-shadow: 0 12px 30px rgba(178, 43, 7, 0.08); /* Premium shadow feedback */
    border-color: rgba(178, 43, 7, 0.18);
}

.service-icon {
    width: 32px;
    height: 32px;
    margin-bottom: 12px;
    color: var(--brand-color);
    display: block;
}

.service-card h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 4px;
}

.service-card p {
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* Hover Isolation Logic (Desktop Only) */
@media (hover: hover) and (pointer: fine) {
    .services-grid:hover .anim-bun,
    .services-grid:hover .icon-groceries,
    .services-grid:hover .pill-left,
    .services-grid:hover .pill-right,
    .services-grid:hover .icon-packages,
    .services-grid:hover .icon-bills,
    .services-grid:hover .anim-check {
        animation-play-state: paused !important;
    }

    .services-grid .service-card:hover .anim-bun,
    .services-grid .service-card:hover .icon-groceries,
    .services-grid .service-card:hover .pill-left,
    .services-grid .service-card:hover .pill-right,
    .services-grid .service-card:hover .icon-packages,
    .services-grid .service-card:hover .icon-bills,
    .services-grid .service-card:hover .anim-check {
        animation-play-state: running !important;
        animation-duration: 3s !important;
        animation-delay: 2s !important;
    }
}

/* Custom Service Icon Keyframes */
@keyframes bunBounce {
    0%, 16.66%, 100% { transform: translateY(0); }
    8.33% { transform: translateY(-4px); }
}
.anim-bun {
    animation: bunBounce 6s infinite ease-in-out;
    animation-delay: 0s;
}

@keyframes cartRoll {
    0%, 16.66%, 100% { transform: translateX(0) rotate(0deg); }
    8.33% { transform: translateX(4px) rotate(4deg); }
}
.icon-groceries {
    animation: cartRoll 6s infinite ease-in-out;
    animation-delay: 1s;
}

@keyframes detachLeft {
    0%, 16.66%, 100% { transform: translateX(0); }
    8.33% { transform: translateX(-4px); }
}
@keyframes detachRight {
    0%, 16.66%, 100% { transform: translateX(0); }
    8.33% { transform: translateX(4px); }
}
.pill-left {
    animation: detachLeft 6s infinite ease-in-out;
    animation-delay: 2s;
}
.pill-right {
    animation: detachRight 6s infinite ease-in-out;
    animation-delay: 2s;
}

@keyframes packageFly {
    0%, 16.66%, 100% { transform: translateY(0); }
    8.33% { transform: translateY(-6px); }
}
.icon-packages {
    animation: packageFly 6s infinite ease-in-out;
    animation-delay: 3s;
}

@keyframes cardSwipe {
    0%, 16.66%, 100% { transform: translateX(0); }
    8.33% { transform: translateX(6px); }
}
.icon-bills {
    animation: cardSwipe 6s infinite ease-in-out;
    animation-delay: 4s;
}

@keyframes checkPop {
    0%, 16.66%, 100% { transform: scale(1); }
    8.33% { transform: scale(1.3); }
}
.anim-check {
    animation: checkPop 6s infinite ease-in-out;
    animation-delay: 5s;
    transform-origin: center;
    transform-box: fill-box;
}

/* MOBILE OVERRIDES (max-width: 868px) */
@media (max-width: 868px) {
    body {
        padding: 35px 20px;
        display: block;
    }

    .app-wrapper {
        display: flex; 
        flex-direction: column;
        gap: 40px;
    }

    .hero-panel {
        align-items: center; 
        gap: 30px;
    }

    .brand-header {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }

    .hero-middle {
        align-items: center;
        text-align: center;
    }

    /* Hide the doodle on mobile */
    .arrow-doodle {
        display: none;
    }

    .button-lead {
        max-width: 100%;
        margin-bottom: 24px;
    }

    /* RESPONSIVE LAYOUT SWITCHING FOR MOBILE */
    .desktop-layout {
        display: none;
    }

    .mobile-layout {
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 100%;
        opacity: 0;
        animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.15s forwards;
    }

    .mobile-connect-footer {
        order: 3;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 28px;
        width: 100%;
        opacity: 0;
        animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.15s forwards;
    }

    .connect-panel-mobile {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 36px;
        width: 100%;
    }

    .contact-block,
    .social-block,
    .mail-block {
        align-items: center;
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }

    .location-group-mobile {
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        margin-top: 0;
    }

    .location-group-mobile .location {
        font-size: 0.95rem;
        color: var(--text-muted);
        font-weight: 700;
        margin-bottom: 6px;
    }

    .location-group-mobile .footer-text {
        font-size: 0.75rem;
        color: var(--text-muted);
    }

    .services-panel {
        order: 2;
    }

    .services-header-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .services-subtext {
        text-align: left;
        padding-left: 14px;
        font-size: 1.25rem;
    }

    .services-heading {
        font-size: 1.3rem;
    }

    .services-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .service-card {
        padding: 16px 20px;
        display: flex;
        align-items: center;
        text-align: left;
        gap: 16px;
    }

    .service-icon {
        margin-bottom: 0;
        flex-shrink: 0;
    }

    .blob-cursor {
        animation: randomRoam 20s ease-in-out infinite alternate !important;
    }
}

@keyframes randomRoam {
    0% { transform: translate(10vw, 10vh) scale(1); }
    33% { transform: translate(50vw, 60vh) scale(1.15); }
    66% { transform: translate(-10vw, 80vh) scale(0.9); }
    100% { transform: translate(40vw, -10vh) scale(1.2); }
}
