/* Runtime fixes layered on top of the original design. */
.gradient-bg { background-attachment: scroll !important; }
#about, #products, #projects, #catalogs, #contact, #delivery { content-visibility: auto; contain-intrinsic-size: 900px; }

.catalog-gallery {
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.catalog-tab {
    border: 0;
    font: inherit;
}

.catalog-tab:focus-visible,
.catalog-gallery-item:focus-visible,
.catalog-category-card:focus-visible,
.catalog-cover-card:focus-visible,
.catalog-back:focus-visible,
#catalogs [role="button"]:focus-visible {
    outline: 3px solid #f59e0b;
    outline-offset: 3px;
}

.catalog-gallery-item {
    aspect-ratio: 3 / 4;
    min-height: 260px;
}

.catalog-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.catalog-fullsize-image {
    width: auto;
    max-width: min(92vw, 720px);
    max-height: 82vh;
    object-fit: contain;
    background: white;
    transform-origin: center;
    transition: transform .18s ease;
    touch-action: none;
}

.site-theme-toggle {
    border: 1px solid rgba(255,255,255,.28);
    background: rgba(255,255,255,.1);
    color: white;
    border-radius: 999px;
    padding: .55rem .85rem;
    display: inline-flex;
    gap: .5rem;
    align-items: center;
    font: inherit;
    font-size: .82rem;
    cursor: pointer;
    backdrop-filter: blur(10px);
}

.product-image-wrapper {
    width: 100%;
    height: 180px;
    margin: -2rem -2rem 1.4rem;
    width: calc(100% + 4rem);
    position: relative;
    z-index: 1;
    overflow: hidden;
    background: #e2e8f0;
}

.product-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .45s ease;
}

.product-card:hover .product-image-wrapper img { transform: scale(1.06); }
.product-card > h3, .product-card > p { position: relative; z-index: 1; }

.service-product-layout { display: block; }
.service-product-layout.has-image { display: grid; grid-template-columns: minmax(220px, 34%) minmax(0, 1fr); gap: 1.5rem; align-items: start; }
.service-product-image { border: 0; padding: 0; border-radius: 16px; overflow: hidden; background: #e2e8f0; cursor: zoom-in; min-height: 300px; position: sticky; top: 0; }
.service-product-image img { width: 100%; height: 100%; min-height: 300px; object-fit: cover; display: block; }
.service-product-copy { min-width: 0; }

.projects-folder-toggle {
    width: min(980px, 100%);
    margin: -1.5rem auto 2rem;
    min-height: 132px;
    padding: 1.25rem 1.45rem;
    border: 1px solid color-mix(in srgb, var(--primary-color, #667eea) 24%, #cbd5e1);
    border-radius: 18px;
    background: linear-gradient(135deg, #fff, #f8fafc);
    color: #1e293b;
    box-shadow: 0 16px 36px rgba(15,23,42,.09);
    display: grid;
    grid-template-columns: auto minmax(150px, 1fr) minmax(270px, .9fr) auto auto;
    align-items: center;
    gap: .9rem;
    text-align: right;
    cursor: pointer;
    font: inherit;
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.projects-folder-toggle:hover { transform: translateY(-3px); box-shadow: 0 24px 48px rgba(15,23,42,.16); border-color: var(--primary-color, #667eea); }
.projects-folder-icon { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; color: white; background: linear-gradient(135deg, var(--primary-color, #667eea), var(--secondary-color, #764ba2)); font-size: 1.25rem; }
.projects-folder-copy { display: grid; gap: .15rem; }
.projects-folder-toggle strong { font-size: 1.08rem; }
.projects-folder-toggle small { color: #64748b; }
.projects-folder-previews {
    direction: ltr;
    min-width: 270px;
    height: 92px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-inline: 20px;
    isolation: isolate;
}
.projects-folder-previews > span {
    width: 76px;
    height: 76px;
    flex: 0 0 76px;
    margin-left: -31px;
    border: 3px solid #fff;
    border-radius: 15px;
    overflow: hidden;
    background: #e2e8f0;
    box-shadow: 0 12px 24px rgba(15,23,42,.23);
    transform: translateY(var(--preview-lift, 0)) rotate(var(--preview-angle, 0));
    animation: project-preview-pop .62s cubic-bezier(.2,.9,.25,1.25) both;
    animation-delay: calc(var(--preview-index, 0) * 85ms);
    transition: transform .3s ease, margin .3s ease, box-shadow .3s ease;
}
.projects-folder-previews > span:first-child { margin-left: 0; }
.projects-folder-previews > span:nth-child(1) { --preview-index: 0; --preview-angle: -8deg; --preview-lift: 5px; }
.projects-folder-previews > span:nth-child(2) { --preview-index: 1; --preview-angle: 6deg; --preview-lift: -5px; }
.projects-folder-previews > span:nth-child(3) { --preview-index: 2; --preview-angle: -4deg; --preview-lift: 3px; }
.projects-folder-previews > span:nth-child(4) { --preview-index: 3; --preview-angle: 7deg; --preview-lift: -6px; }
.projects-folder-previews > span:nth-child(5) { --preview-index: 4; --preview-angle: -6deg; --preview-lift: 4px; }
.projects-folder-previews > span:nth-child(6) { --preview-index: 5; --preview-angle: 5deg; --preview-lift: -3px; }
.projects-folder-previews img { width: 100%; height: 100%; display: block; object-fit: cover; }
.projects-folder-toggle:hover .projects-folder-previews > span { margin-left: -22px; box-shadow: 0 16px 28px rgba(15,23,42,.28); }
.projects-folder-toggle:hover .projects-folder-previews > span:first-child { margin-left: 0; }
.projects-folder-state { color: var(--primary-color, #667eea); font-weight: 800; }
.projects-folder-chevron { transition: transform .25s ease; }
#projects.projects-expanded .projects-folder-chevron { transform: rotate(180deg); }

@keyframes project-preview-pop {
    from { opacity: 0; transform: translateY(26px) scale(.72) rotate(0); }
    to { opacity: 1; transform: translateY(var(--preview-lift, 0)) scale(1) rotate(var(--preview-angle, 0)); }
}

/* هياكل الصفحة: مستقلة عن الثيم والألوان. */
html[data-site-layout="showcase"] #home { min-height: 82vh; text-align: right; }
html[data-site-layout="showcase"] #home .container { max-width: 1180px; }
html[data-site-layout="showcase"] #home .logo-circle { margin-right: 0; }
html[data-site-layout="showcase"] #home p { margin-right: 0; }
html[data-site-layout="showcase"] #products .container > .grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
html[data-site-layout="showcase"] .product-card { display: grid; grid-template-columns: 170px minmax(0, 1fr); grid-template-rows: auto 1fr; column-gap: 1.25rem; text-align: right; align-items: center; }
html[data-site-layout="showcase"] .product-image-wrapper { grid-row: 1 / 3; width: 170px; height: 170px; margin: 0; border-radius: 14px; }
html[data-site-layout="showcase"] .product-icon-wrapper { grid-row: 1 / 3; margin: 0; }
html[data-site-layout="showcase"] #projects .managed-project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
html[data-site-layout="showcase"] #projects .managed-project-grid .project-card:first-child { grid-column: 1 / -1; }
html[data-site-layout="showcase"] #projects .managed-project-grid .project-card:first-child img { height: 25rem; }

html[data-site-layout="editorial"] #about > .container,
html[data-site-layout="editorial"] #products > .container,
html[data-site-layout="editorial"] #projects > .container,
html[data-site-layout="editorial"] #catalogs > .container { display: grid; grid-template-columns: minmax(220px, .34fr) minmax(0, 1fr); gap: 2.25rem; align-items: start; }
html[data-site-layout="editorial"] #about .container > .text-center,
html[data-site-layout="editorial"] #products .container > .text-center,
html[data-site-layout="editorial"] #projects .container > .text-center,
html[data-site-layout="editorial"] #catalogs .container > .text-center { position: sticky; top: 110px; text-align: right; margin-bottom: 0; }
html[data-site-layout="editorial"] #about .container > .grid,
html[data-site-layout="editorial"] #products .container > .grid,
html[data-site-layout="editorial"] #projects .container > .grid,
html[data-site-layout="editorial"] #catalogs .container > :not(.text-center) { grid-column: 2; }
html[data-site-layout="editorial"] #products .container > .grid { grid-template-columns: 1fr !important; }
html[data-site-layout="editorial"] .product-card { display: grid; grid-template-columns: 120px minmax(0, 1fr); text-align: right; column-gap: 1.25rem; align-items: center; }
html[data-site-layout="editorial"] .product-image-wrapper { width: 120px; height: 120px; margin: 0; grid-row: 1 / 3; border-radius: 12px; }
html[data-site-layout="editorial"] .product-icon-wrapper { grid-row: 1 / 3; margin: 0; }

html[data-site-layout="compact"] section { padding-top: 3.5rem !important; padding-bottom: 3.5rem !important; }
html[data-site-layout="compact"] #home { min-height: 66vh; }
html[data-site-layout="compact"] #home .logo-circle { width: 92px; height: 92px; margin-bottom: 1.1rem; }
html[data-site-layout="compact"] #products .container > .grid { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; gap: 1rem; }
html[data-site-layout="compact"] .product-card { padding: 1.25rem; }
html[data-site-layout="compact"] .product-image-wrapper { height: 135px; margin: -1.25rem -1.25rem 1rem; width: calc(100% + 2.5rem); }
html[data-site-layout="compact"] .product-icon-wrapper { width: 64px; height: 64px; margin-bottom: 1rem; }
html[data-site-layout="compact"] .managed-section-gallery { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.managed-section-gallery {
    margin-top: 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
}

.managed-section-image {
    position: relative;
    min-height: 210px;
    overflow: hidden;
    padding: 0;
    border: 0;
    border-radius: 16px;
    background: #e2e8f0;
    cursor: zoom-in;
    box-shadow: 0 12px 28px rgba(15,23,42,.12);
}

.managed-section-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.managed-section-image:hover img { transform: scale(1.05); }
.managed-section-image span { position:absolute; inset:auto 0 0; padding:.75rem; color:white; background:linear-gradient(transparent,rgba(0,0,0,.8)); font-weight:700; }

.managed-catalog-book { padding: 1.25rem; margin-bottom: 1.25rem; border: 1px solid #e2e8f0; border-radius: 18px; background: white; box-shadow: 0 14px 34px rgba(15,23,42,.08); }
.managed-catalog-heading { display:flex; justify-content:space-between; gap:1rem; align-items:flex-start; margin-bottom:1rem; }
.managed-catalog-heading small { color: var(--primary-color, #667eea); font-weight:800; }
.managed-catalog-heading h4 { font-size:1.35rem; font-weight:800; margin:.15rem 0; }
.managed-catalog-heading p { color:#64748b; }
.managed-book-badge { white-space:nowrap; display:inline-flex; align-items:center; gap:.4rem; padding:.5rem .75rem; border-radius:999px; background:#f1f5f9; color:#334155; font-size:.82rem; }

.catalog-reader-toolbar { display:flex; justify-content:center; align-items:center; gap:.45rem; flex-wrap:wrap; margin:0 2.75rem .75rem; }
.catalog-reader-toolbar button { border:0; border-radius:10px; min-width:38px; height:38px; padding:0 .65rem; background:#e2e8f0; color:#0f172a; cursor:pointer; font:inherit; font-weight:800; }
.catalog-reader-toolbar button:disabled { opacity:.35; cursor:not-allowed; }
.catalog-reader-toolbar span { min-width:64px; text-align:center; font-weight:800; }
.catalog-image-viewport { width:min(92vw,900px); height:min(72vh,760px); display:grid; place-items:center; overflow:auto; touch-action:none; overscroll-behavior:contain; background:radial-gradient(circle at center,#fff,#e2e8f0); border-radius:14px; }
.catalog-image-viewport .catalog-fullsize-image { max-width:90%; max-height:90%; }
.page-turn-next { animation: pageTurnNext .42s cubic-bezier(.2,.7,.2,1); }
.page-turn-prev { animation: pageTurnPrev .42s cubic-bezier(.2,.7,.2,1); }
@keyframes pageTurnNext { from { opacity:.2; transform:perspective(1200px) rotateY(-16deg) translateX(-24px) scale(.96); } to { opacity:1; transform:perspective(1200px) rotateY(0) translateX(0) scale(1); } }
@keyframes pageTurnPrev { from { opacity:.2; transform:perspective(1200px) rotateY(16deg) translateX(24px) scale(.96); } to { opacity:1; transform:perspective(1200px) rotateY(0) translateX(0) scale(1); } }

html[data-site-theme="atelier"] .section-title { letter-spacing:.02em; }
html[data-site-theme="atelier"] .product-card,
html[data-site-theme="atelier"] .project-card { box-shadow:0 16px 38px rgba(65,45,35,.12); }
html[data-site-theme="blueprint"] .section-title::after { height:2px; }
html[data-site-theme="blueprint"] .product-card { border:1px solid rgba(98,198,232,.3); }
html[data-site-theme="stone"] .product-card,
html[data-site-theme="stone"] .project-card,
html[data-site-theme="stone"] .managed-catalog-book { border-radius:2px !important; }

html[data-theme-mode="dark"] body { background:#0b1118 !important; color:#e5edf6; }
html[data-theme-mode="dark"] #home,
html[data-theme-mode="dark"] #home h1,
html[data-theme-mode="dark"] #home p { color:#fff !important; }
html[data-theme-mode="dark"] #home .bg-white { background-color:#fbfbfc !important; color:#2563eb !important; }
html[data-theme-mode="dark"] #about,
html[data-theme-mode="dark"] #projects,
html[data-theme-mode="dark"] #delivery { background:#111a24 !important; }
html[data-theme-mode="dark"] #products,
html[data-theme-mode="dark"] #catalogs { background:#0b1118 !important; }
html[data-theme-mode="dark"] .product-card,
html[data-theme-mode="dark"] .project-card,
html[data-theme-mode="dark"] .managed-catalog-book,
html[data-theme-mode="dark"] .catalog-category-card,
html[data-theme-mode="dark"] .catalog-cover-card { background:#17212d !important; color:#eef4fb; border-color:#2b3a4b; }
html[data-theme-mode="dark"] .text-gray-600,
html[data-theme-mode="dark"] .managed-catalog-heading p { color:#aebdcd !important; }
html[data-theme-mode="dark"] .catalog-level-intro h4 { color:#f1f5f9; }
html[data-theme-mode="dark"] .catalog-level-intro p,
html[data-theme-mode="dark"] .catalog-card-copy span,
html[data-theme-mode="dark"] .catalog-cover-copy small { color:#aebdcd; }
html[data-theme-mode="dark"] .catalog-level-intro > span { background:#24364b; color:#8fc2ff; }
html[data-theme-mode="dark"] .catalog-card-copy em { color:#d8e2ee; }
html[data-theme-mode="dark"] .catalog-content,
html[data-theme-mode="dark"] .catalog-image-content,
html[data-theme-mode="dark"] .service-content { background:#111a24; color:#eef4fb; }
html[data-theme-mode="dark"] .catalog-image-viewport { background:radial-gradient(circle at center,#253244,#0c121a); }
html[data-theme-mode="dark"] .text-gray-800,
html[data-theme-mode="dark"] .text-gray-700 { color:#f1f5f9 !important; }
html[data-theme-mode="dark"] .text-gray-500,
html[data-theme-mode="dark"] .text-gray-600 { color:#b8c5d4 !important; }
html[data-theme-mode="dark"] .bg-white,
html[data-theme-mode="dark"] .bg-gray-50,
html[data-theme-mode="dark"] .bg-gray-100 { background-color:#17212d !important; }
html[data-theme-mode="dark"] .service-details { color:#d8e2ee; }
html[data-theme-mode="dark"] .service-details h3 { color:#8fc2ff !important; border-bottom-color:#334155; }
html[data-theme-mode="dark"] .service-feature { background:#1b2837; color:#edf4fb; box-shadow:0 2px 6px rgba(0,0,0,.28); }
html[data-theme-mode="dark"] .service-feature:hover { background:#22354a; }
html[data-theme-mode="dark"] .service-feature i { color:#69a9ff; }
html[data-theme-mode="dark"] .product-icon-wrapper { background:#24364b !important; }
html[data-theme-mode="dark"] .product-icon { color:#7db7ff !important; }
html[data-theme-mode="dark"] .product-card:hover .product-icon { color:#fff !important; }
html[data-theme-mode="dark"] .managed-book-badge,
html[data-theme-mode="dark"] .catalog-reader-toolbar button { background:#253447; color:#f1f5f9; }
html[data-theme-mode="dark"] .managed-empty { background:#111a24; color:#b8c5d4; border-color:#475569; }
html[data-theme-mode="dark"] .projects-folder-toggle { background:linear-gradient(135deg,#17212d,#111a24); color:#f1f5f9; border-color:#3b4a5d; }
html[data-theme-mode="dark"] .projects-folder-toggle small { color:#aebdcd; }
html[data-theme-mode="dark"] .projects-folder-state { color:#8fc2ff; }
html[data-theme-mode="dark"] .projects-folder-previews > span { border-color:#263648; }
html[data-theme-mode="dark"] .catalog-tab:not(.active) { background:#253447; color:#e5edf6; }
html[data-theme-mode="dark"] .service-product-image { background:#0b1118; }

.managed-empty {
    border: 2px dashed #cbd5e1;
    border-radius: 12px;
    padding: 28px;
    text-align: center;
    color: #64748b;
    background: #f8fafc;
}

.managed-image-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 192px;
    padding: 20px;
    background: linear-gradient(135deg, #e2e8f0, #f8fafc);
    color: #475569;
    font-weight: 700;
    text-align: center;
}

@media (max-width: 768px) {
    html, body { width: 100%; max-width: 100%; overflow-x: clip; }
    header > .container { gap: .65rem; }
    header > .container > .flex { min-width: 0; flex: 1 1 auto; }
    header > .container > .flex > span {
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        font-size: 1rem;
    }
    header .header-logo { width: 40px; height: 40px; flex: 0 0 40px; }
    #home { padding-inline: 0; }
    #home .container { width: 100%; max-width: 100%; }
    #home h1 { font-size: clamp(2rem, 10vw, 2.75rem); line-height: 1.35; overflow-wrap: anywhere; }
    #home p { max-width: 100%; }
    #home .space-x-4 {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }
    #home .space-x-4 > a { margin: 0 !important; display: inline-flex; align-items: center; justify-content: center; }
    .floating-contact { right: auto !important; left: 12px; bottom: 12px; }
    .floating-contact a { width: 48px; height: 48px; font-size: 20px; }

    .catalog-gallery {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .catalog-gallery-item {
        min-height: 220px;
    }

    .site-theme-toggle span { display:none; }
    .site-theme-toggle { padding:.6rem; }
    .catalog-image-viewport { width:94vw; height:68vh; }
    .managed-catalog-heading { flex-direction:column; }
    .service-product-layout.has-image { grid-template-columns: 1fr; }
    .service-product-image { position: static; min-height: 220px; max-height: 320px; }
    .service-product-image img { min-height: 220px; max-height: 320px; }
    .projects-folder-toggle {
        grid-template-columns: auto minmax(0, 1fr) auto;
        min-height: 0;
        padding: 1rem;
        margin-top: -1rem;
    }
    .projects-folder-previews {
        grid-column: 1 / -1;
        min-width: 0;
        width: 100%;
        height: 80px;
        padding-inline: 8px;
    }
    .projects-folder-previews > span { width: 64px; height: 64px; flex-basis: 64px; margin-left: -25px; border-radius: 12px; }
    .projects-folder-previews > span:first-child { margin-left: 0; }
    .projects-folder-state { display:none; }
    html[data-site-layout="showcase"] #products .container > .grid,
    html[data-site-layout="compact"] #products .container > .grid { grid-template-columns: 1fr !important; }
    html[data-site-layout="showcase"] .product-card,
    html[data-site-layout="editorial"] .product-card { grid-template-columns: 96px minmax(0,1fr); padding:1rem; }
    html[data-site-layout="showcase"] .product-image-wrapper,
    html[data-site-layout="editorial"] .product-image-wrapper { width:96px; height:96px; }
    html[data-site-layout="editorial"] #about > .container,
    html[data-site-layout="editorial"] #products > .container,
    html[data-site-layout="editorial"] #projects > .container,
    html[data-site-layout="editorial"] #catalogs > .container { display:block; }
    html[data-site-layout="editorial"] #about .container > .text-center,
    html[data-site-layout="editorial"] #products .container > .text-center,
    html[data-site-layout="editorial"] #projects .container > .text-center,
    html[data-site-layout="editorial"] #catalogs .container > .text-center { position:static; text-align:center; margin-bottom:2.5rem; }
}

@media (max-width: 420px) {
    header .header-logo { display: none; }
    header > .container > .flex > span { font-size: .95rem; }
    #home .logo-circle { width: 104px; height: 104px; }
    #home .space-x-4 > a { width: min(100%, 245px); }
    .projects-folder-toggle { padding-inline: .8rem; }
    .projects-folder-icon { width: 44px; height: 44px; }
    .projects-folder-toggle strong { font-size: 1rem; }
    .projects-folder-toggle small { font-size: .75rem; }
    .projects-folder-previews > span { width: 56px; height: 56px; flex-basis: 56px; margin-left: -21px; border-width: 2px; }
}

/* Final brand and full-image reader corrections. */
.header-logo,
.footer-logo,
.logo-circle,
.opening-motion__logo {
    background-color: transparent !important;
    background-image: url('/brand-logo-transparent-v2.png') !important;
    background-size: contain !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    filter: drop-shadow(0 0 2px rgba(255,255,255,.95)) drop-shadow(0 9px 15px rgba(0,0,0,.3)) saturate(1.08);
}

.catalog-image-content {
    height: min(98svh, 980px) !important;
    display: grid !important;
    grid-template-rows: auto auto minmax(0, 1fr) auto !important;
    overflow: hidden !important;
}
.catalog-image-viewport {
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    display: grid !important;
    place-items: center !important;
    overflow: hidden !important;
    touch-action: none;
}
.catalog-image-viewport .catalog-fullsize-image {
    display: block !important;
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    object-fit: contain !important;
    object-position: center !important;
    margin: 0 !important;
    touch-action: none;
}
.catalog-code-field { margin-top: .75rem; }

@media (max-width: 768px) {
    .catalog-image-content { width: 100vw !important; height: 100svh !important; max-height: 100svh !important; }
    .catalog-image-viewport { width: calc(100vw - .8rem) !important; height: auto !important; min-height: 0 !important; }
}

@media (hover: none) {
    .project-card .absolute.bottom-4 {
        opacity: 1 !important;
        transform: translateY(0) !important;
        padding: 0.5rem;
        border-radius: 0.5rem;
        background: rgba(0, 0, 0, 0.62);
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}


/* Agricultural-green identity and cinematic trade tools */
:root {
    --field-50: #f5faee;
    --field-100: #eaf5dc;
    --field-200: #d4eab7;
    --field-500: #63a84b;
    --field-600: #3d8752;
    --field-700: #24643f;
    --field-900: #0d3527;
}
html, body { background: var(--field-50); }
header.bg-gray-900, #contact.bg-gray-900 { background: linear-gradient(135deg, #0a3023, #174c33 62%, #315e37) !important; }
#about { background: linear-gradient(180deg, #f7fbf0, #eaf5dc) !important; }
#products { background: linear-gradient(145deg, #edf7e3, #f9fcf4) !important; }
#projects { background: linear-gradient(160deg, #dcefc7, #f4faed) !important; }
#catalogs { background: linear-gradient(180deg, #f7fbf1, #e4f2d4) !important; }
.bg-blue-600, .bg-purple-600 { background-color: var(--field-600) !important; }
.bg-blue-500 { background-color: #79ad3f !important; }
.bg-blue-100, .bg-purple-100 { background-color: #dff0c9 !important; }
.text-blue-600, .text-purple-600 { color: var(--field-700) !important; }
.hover\:text-blue-400:hover, .hover\:text-purple-400:hover { color: #b9e51b !important; }
.section-title { color: #153d2b !important; }
#contact .section-title { color: white !important; }
.product-card:hover { border-color: var(--field-500) !important; box-shadow: 0 20px 40px rgba(36,100,63,.2) !important; }
.product-card::before { background: linear-gradient(135deg, rgba(99,168,75,.12), rgba(185,229,27,.13)) !important; }
.product-icon-wrapper { background-color: #dff0c9 !important; }
.product-card:hover .product-icon-wrapper { background-color: var(--field-600) !important; }
.product-icon { color: var(--field-700) !important; }
.gallery-header, .service-header, .catalog-header { background: linear-gradient(135deg, #174c33, #63a84b) !important; }
.service-details h3 { color: var(--field-700) !important; border-bottom-color: #cfe4b9 !important; }

.header-logo, .footer-logo, .logo-circle, .opening-motion__logo {
    background-color: transparent !important;
    background-image: url('/brand-logo-transparent-v2.png') !important;
    border: 0 !important;
    box-shadow: none !important;
    background-size: contain !important;
    filter: drop-shadow(0 10px 16px rgba(6,36,24,.2));
}
.logo-circle {
    position: relative;
    overflow: visible !important;
    animation: kinetic-logo-rise 1.05s cubic-bezier(.2,.9,.25,1.2) both;
}
.logo-circle::before, .logo-circle::after {
    content: "";
    position: absolute;
    left: 4%;
    right: 4%;
    height: 26%;
    border: 6px solid #4ea83b;
    opacity: .75;
    pointer-events: none;
    animation: logo-arc-draw 1.25s cubic-bezier(.2,.8,.2,1) both;
}
.logo-circle::before { top: 1%; border-width: 6px 6px 0; border-radius: 90% 90% 0 0; transform-origin: right; }
.logo-circle::after { bottom: 2%; border-width: 0 6px 6px; border-radius: 0 0 90% 90%; transform-origin: left; animation-delay: .16s; }
@keyframes kinetic-logo-rise { from { opacity: 0; transform: translateY(25px) scale(.84); } to { opacity: 1; transform: none; } }
@keyframes logo-arc-draw { from { clip-path: inset(0 100% 0 0); opacity: 0; } to { clip-path: inset(0 0 0 0); opacity: .7; } }

.paint-can.paint-can--real {
    width: clamp(205px, 27vw, 330px);
    height: auto;
    aspect-ratio: auto;
    object-fit: contain;
    background: none;
    border-radius: 0;
    box-shadow: none;
    filter: drop-shadow(0 34px 28px rgba(0,0,0,.34)) drop-shadow(0 6px 6px rgba(185,229,27,.16));
    transform: translate3d(calc(var(--paint-scroll, 0) * -35px), calc(var(--paint-scroll, 0) * 62px), 0) rotateZ(calc(-7deg + var(--paint-scroll, 0) * 20deg)) rotateY(calc(var(--paint-pointer-x, 0) * 11deg)) rotateX(calc(var(--paint-pointer-y, 0) * -5deg));
    animation: bucket-breathe 4.8s ease-in-out infinite;
}
.paint-can.paint-can--real::before, .paint-can.paint-can--real::after { display: none; }
@keyframes bucket-breathe { 0%,100% { margin-top: 0; } 50% { margin-top: -9px; } }

.paint-roller--real {
    background: linear-gradient(180deg, #f8f1dc 0 16%, #d6e8a9 17% 48%, #91c74d 49% 82%, #ecf5cf 83%);
    border: 3px solid rgba(27,65,43,.24);
    box-shadow: inset 0 4px 8px rgba(255,255,255,.8), inset 0 -6px 10px rgba(47,103,61,.18), 0 16px 26px rgba(0,0,0,.25);
}
.paint-roller--real::before {
    content: "";
    position: absolute;
    inset: 5px 7px;
    border-radius: 8px;
    background: repeating-linear-gradient(95deg, rgba(255,255,255,.45) 0 3px, transparent 3px 9px);
}
.paint-roller--real::after { border-color: #c9d1cb; filter: drop-shadow(3px 4px 2px rgba(0,0,0,.22)); }
.paint-roller--real span { background: linear-gradient(90deg, #142b22, #4f665c, #162f25); box-shadow: inset 3px 0 rgba(255,255,255,.12), 5px 7px 12px rgba(0,0,0,.24); }

.phone-call-action {
    text-decoration: none;
    color: white;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(4,35,23,.3);
    animation: phone-pulse 2.4s ease-in-out infinite;
}
.phone-call-action:active { transform: scale(.9); }
.contact-phone-list { display: grid; justify-content: center; gap: .35rem; }
.contact-phone-list a { color: #d1d5db; text-decoration: none; direction: ltr; font-weight: 750; transition: color .2s ease, transform .2s ease; }
.contact-phone-list a:hover, .contact-phone-list a:focus-visible { color: #b9e51b; transform: translateY(-1px); }
@keyframes phone-pulse { 0%,100% { box-shadow: 0 0 0 0 rgba(185,229,27,0), 0 10px 24px rgba(4,35,23,.3); } 50% { box-shadow: 0 0 0 12px rgba(185,229,27,.12), 0 10px 24px rgba(4,35,23,.3); } }

@media (max-width: 768px) {
    .paint-can.paint-can--real { width: 178px; left: 6%; top: 11%; }
}
@media (prefers-reduced-motion: reduce) {
    .paint-can.paint-can--real, .phone-call-action, .logo-circle { animation: none !important; }
}


/* Paint Comes Alive — industrial identity and cinematic hero. */
:root {
    --paint-deep: #0b2d24;
    --paint-green: #0f6b46;
    --paint-lime: #b9e51b;
    --paint-sand: #d7c3a1;
    --paint-warm: #f8f4e8;
    --paint-red: #c83a32;
}

body.modal-open { overflow: hidden !important; }

.logo-circle,
.header-logo,
.footer-logo,
.opening-motion__logo {
    background-image: url('/brand-logo-2026.jpg') !important;
    background-size: contain !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
}

.header-logo { flex: 0 0 68px; }
.footer-logo { width: 104px; height: 74px; flex: 0 0 104px; }

.paint-hero.gradient-bg {
    min-height: min(900px, calc(100svh - 72px)) !important;
    padding: clamp(4.5rem, 8vw, 7rem) 0 clamp(3.5rem, 7vw, 6rem) !important;
    display: flex;
    align-items: center;
    text-align: right;
    overflow: hidden;
    position: relative;
    isolation: isolate;
    background-image:
        radial-gradient(circle at 18% 20%, rgba(185, 229, 27, .20), transparent 28%),
        linear-gradient(118deg, rgba(7, 34, 27, .96), rgba(15, 107, 70, .86)),
        var(--managed-hero-image, url('/uploads/4f85fa8be655b4d81bf2c0da22295480e8d7a2b9.jpg')) !important;
    background-size: cover !important;
    background-position: center !important;
}

.paint-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    opacity: .34;
    background:
        repeating-linear-gradient(8deg, rgba(255,255,255,.045) 0 1px, transparent 1px 11px),
        radial-gradient(circle at 70% 35%, transparent 0 22%, rgba(0,0,0,.2) 70%);
    mix-blend-mode: soft-light;
    pointer-events: none;
}

.paint-hero::after {
    content: '';
    position: absolute;
    inset: auto -10% -36% 38%;
    height: 58%;
    z-index: -1;
    border-radius: 48% 52% 0 0;
    background: linear-gradient(100deg, rgba(185,229,27,.44), rgba(15,107,70,.15));
    filter: blur(12px);
    transform: rotate(-5deg);
}

.paint-hero__grid {
    width: min(1180px, 100%);
    display: grid;
    grid-template-columns: minmax(0, 1.02fr) minmax(360px, .98fr);
    gap: clamp(2rem, 6vw, 5rem);
    align-items: center;
}

.paint-hero__copy { position: relative; z-index: 3; min-width: 0; }
.paint-hero__brand { display: inline-flex; flex-direction: column; align-items: flex-start; gap: .65rem; margin-bottom: 1.25rem; }
.paint-hero__brand > span { color: #d9f78a; font-size: .92rem; font-weight: 800; letter-spacing: .02em; }
.paint-hero__brand .logo-circle { margin: 0; width: 210px !important; height: 142px !important; border-radius: 24px !important; }
.paint-hero h1 { max-width: 760px; font-size: clamp(2.5rem, 5.6vw, 5.2rem) !important; line-height: 1.08 !important; text-wrap: balance; text-shadow: 0 16px 45px rgba(0,0,0,.34); }
.paint-hero__copy > p { max-width: 680px; margin-right: 0 !important; color: rgba(255,255,255,.88); }

.hero-actions { display: flex; flex-wrap: wrap; gap: .85rem; justify-content: flex-start; }
.hero-action { min-height: 50px; padding: .78rem 1.35rem; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; margin: 0 !important; font-weight: 800; transition: transform .2s ease, background .2s ease, color .2s ease, box-shadow .2s ease; }
.hero-action:hover { transform: translateY(-2px); }
.hero-action--primary { color: #08291f; background: var(--paint-lime); box-shadow: 0 13px 32px rgba(185,229,27,.22); }
.hero-action--secondary { color: white; border: 1px solid rgba(255,255,255,.62); background: rgba(255,255,255,.08); backdrop-filter: blur(10px); }

.paint-hero__stats { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.35rem; }
.paint-hero__stats span { min-width: 112px; padding: .65rem .85rem; border: 1px solid rgba(255,255,255,.18); border-radius: 16px; background: rgba(3,20,15,.32); color: rgba(255,255,255,.78); backdrop-filter: blur(10px); font-size: .82rem; }
.paint-hero__stats strong { display: block; color: white; font-size: 1.3rem; line-height: 1; margin-bottom: .28rem; }

.paint-hero__stage { position: relative; min-height: 520px; border-radius: 42% 58% 48% 52% / 42% 38% 62% 58%; background: radial-gradient(circle at 46% 36%, rgba(255,255,255,.20), rgba(255,255,255,.035) 58%, transparent 59%); perspective: 1200px; }
.paint-motion-canvas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }

.paint-can { position: absolute; width: clamp(180px, 24vw, 285px); aspect-ratio: .9; left: 12%; top: 22%; border-radius: 22px 22px 34px 34px; background: linear-gradient(90deg, #d8ded7, #fff 40%, #b7c2ba 92%); box-shadow: 0 34px 70px rgba(0,0,0,.34); transform-style: preserve-3d; transform: translate3d(calc(var(--paint-scroll, 0) * -35px), calc(var(--paint-scroll, 0) * 70px), 0) rotateZ(calc(-8deg + var(--paint-scroll, 0) * 24deg)) rotateY(calc(var(--paint-pointer-x, 0) * 8deg)); transition: transform .08s linear; }
.paint-can::before { content: ''; position: absolute; left: 8%; right: 8%; top: -9%; height: 17%; border: 9px solid #cbd2cc; border-bottom: 0; border-radius: 50% 50% 0 0; }
.paint-can::after { content: ''; position: absolute; inset: 15% 0 auto; height: 48%; background: linear-gradient(105deg, #0f6b46, #b9e51b); box-shadow: inset 0 1px rgba(255,255,255,.4); }
.paint-can__label { position: absolute; z-index: 2; inset: 19% 8% auto; height: 40%; border-radius: 14px; background: #fff url('/brand-logo-2026.jpg') center / contain no-repeat; box-shadow: 0 5px 20px rgba(0,0,0,.12); }

.paint-drop-character { position: absolute; z-index: 4; width: 92px; height: 112px; right: 5%; top: 48%; border-radius: 58% 42% 54% 46% / 66% 62% 38% 34%; background: linear-gradient(145deg, #d9ff38, #0f8b58 68%, #084d37); box-shadow: inset 16px 12px 24px rgba(255,255,255,.22), 0 24px 50px rgba(0,0,0,.28); transform: translate3d(calc(var(--paint-pointer-x, 0) * 12px), calc(var(--paint-pointer-y, 0) * 9px), 0) rotate(calc(var(--paint-pointer-x, 0) * 4deg)); }
.paint-drop-character::before { content: ''; position: absolute; width: 38px; height: 38px; top: -18px; right: 23px; background: #8ed928; border-radius: 100% 0 100% 100%; transform: rotate(35deg); }
.paint-drop-character__eyes::before,
.paint-drop-character__eyes::after { content: ''; position: absolute; top: 42px; width: 10px; height: 15px; border-radius: 50%; background: #08291f; transform: translate(calc(var(--paint-pointer-x, 0) * 2px), calc(var(--paint-pointer-y, 0) * 2px)); }
.paint-drop-character__eyes::before { right: 27px; }
.paint-drop-character__eyes::after { left: 27px; }

.paint-roller { position: absolute; z-index: 3; width: 156px; height: 38px; left: 2%; top: 70%; border-radius: 10px; background: linear-gradient(#f8f4e8, #d7c3a1); box-shadow: 0 12px 30px rgba(0,0,0,.2); transform: translateX(calc(var(--paint-scroll, 0) * 160px)) rotate(-8deg); }
.paint-roller::after { content: ''; position: absolute; width: 65px; height: 12px; right: -48px; top: 27px; border: 6px solid #d6ddd7; border-left: 0; border-top: 0; transform: skewY(28deg); }
.paint-roller span { position: absolute; width: 18px; height: 88px; right: -61px; top: 58px; border-radius: 999px; background: #20372f; transform: rotate(20deg); }

.catalog-image-modal { overscroll-behavior: contain; }
.catalog-image-content { width: min(98vw, 1180px) !important; max-height: 98svh !important; position: relative; }
.catalog-reader-hint { margin: -.35rem 3rem .55rem; color: #64748b; text-align: center; font-size: .78rem; }
.catalog-image-viewport { position: relative; overflow: hidden !important; user-select: none; cursor: zoom-out; }
.catalog-image-viewport.is-zoomed { cursor: grab; }
.catalog-image-viewport.is-zoomed:active { cursor: grabbing; }
.catalog-image-viewport .catalog-fullsize-image { width: auto; max-width: 88%; max-height: 88%; will-change: transform; }

@media (max-width: 768px) {
    header > .container { min-height: 68px; padding-block: .55rem !important; }
    .site-brand { min-width: 0; max-width: calc(100% - 104px); }
    .site-brand > span { display: block; min-width: 0; max-width: 100%; font-size: clamp(.78rem, 3.5vw, 1rem) !important; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    header .header-logo { display: block !important; width: 56px !important; height: 40px !important; flex-basis: 56px !important; border-radius: 9px; }
    .paint-hero.gradient-bg { min-height: auto !important; padding: 2.35rem 0 3rem !important; text-align: right; }
    .paint-hero__grid { display: flex; flex-direction: column; gap: 1.75rem; }
    .paint-hero__copy { width: 100%; }
    .paint-hero__brand { margin-bottom: .85rem; }
    .paint-hero__brand .logo-circle { width: 150px !important; height: 104px !important; margin: 0 !important; }
    .paint-hero__brand > span { font-size: .78rem; }
    .paint-hero h1 { font-size: clamp(2rem, 10vw, 3rem) !important; line-height: 1.14 !important; margin-bottom: 1rem !important; overflow-wrap: normal !important; }
    .paint-hero__copy > p { font-size: .98rem !important; line-height: 1.75; margin-bottom: 1rem !important; }
    .hero-actions { display: grid !important; grid-template-columns: 1fr; width: 100%; }
    .hero-action { width: 100%; }
    .paint-hero__stats { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: .45rem; }
    .paint-hero__stats span { min-width: 0; padding: .6rem .45rem; text-align: center; font-size: .68rem; }
    .paint-hero__stats strong { font-size: 1.05rem; }
    .paint-hero__stage { width: 100%; min-height: 270px; order: 2; }
    .paint-can { width: 152px; left: 17%; top: 17%; }
    .paint-drop-character { width: 62px; height: 76px; right: 7%; top: 44%; }
    .paint-drop-character::before { width: 25px; height: 25px; top: -12px; right: 16px; }
    .paint-drop-character__eyes::before,
    .paint-drop-character__eyes::after { top: 28px; width: 7px; height: 11px; }
    .paint-drop-character__eyes::before { right: 18px; }
    .paint-drop-character__eyes::after { left: 18px; }
    .paint-roller { width: 105px; height: 28px; top: 72%; }
    .catalog-image-content { width: 100vw !important; height: 100svh; max-width: none !important; max-height: none !important; border-radius: 0 !important; padding: .4rem; display: flex; flex-direction: column; justify-content: center; }
    .catalog-image-close { top: .65rem !important; right: .65rem !important; width: 44px !important; height: 44px !important; z-index: 5; }
    .catalog-reader-toolbar { margin: 3.2rem .25rem .35rem !important; gap: .3rem; }
    .catalog-reader-toolbar button { min-width: 42px; height: 42px; }
    .catalog-reader-hint { margin: 0 .5rem .45rem; font-size: .68rem; }
    .catalog-image-viewport { width: calc(100vw - .8rem) !important; height: min(70svh, 690px) !important; border-radius: 12px; }
    .catalog-image-title { padding: .45rem .75rem; max-height: 3.5rem; overflow: hidden; }
}

@media (max-width: 420px) {
    header .header-logo { display: block !important; }
    .paint-hero__stage { min-height: 240px; }
    .paint-hero__stats { grid-template-columns: repeat(3, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
    .paint-can,
    .paint-drop-character,
    .paint-roller { transform: none !important; }
}


/* Final hero asset overrides: real cutout bucket + interactive drop. */
.paint-can.paint-can--real {
    position: absolute;
    z-index: 2;
    width: clamp(310px, 39vw, 500px) !important;
    height: auto !important;
    aspect-ratio: 1400 / 1123 !important;
    left: -3% !important;
    top: 2% !important;
    border-radius: 0 !important;
    background: none !important;
    box-shadow: none !important;
    overflow: visible !important;
    filter: drop-shadow(0 42px 30px rgba(0,0,0,.34)) drop-shadow(0 7px 7px rgba(185,229,27,.13));
    transform-style: preserve-3d;
    transform: translate3d(calc(var(--paint-scroll, 0) * -26px), calc(var(--paint-scroll, 0) * 52px), 0) rotateZ(calc(-3deg + var(--paint-scroll, 0) * 14deg)) rotateY(calc(var(--paint-pointer-x, 0) * 9deg)) rotateX(calc(var(--paint-pointer-y, 0) * -4deg));
    animation: bucket-breathe 4.8s ease-in-out infinite;
}
.paint-can.paint-can--real::before,
.paint-can.paint-can--real::after { display: none !important; }
.paint-can__photo {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
}
.paint-can__brand-overlay {
    position: absolute;
    z-index: 3;
    width: 19%;
    height: auto;
    left: 70.2%;
    top: 40.2%;
    transform: translate(-50%, -50%) rotate(-1deg);
    filter: saturate(1.1) contrast(1.05);
    mix-blend-mode: multiply;
    pointer-events: none;
}

.paint-drop-character {
    cursor: pointer;
    pointer-events: auto;
    isolation: isolate;
    transition: filter .22s ease, box-shadow .22s ease;
    animation: drop-idle 2.8s ease-in-out infinite;
}
.paint-drop-character::after {
    content: "";
    position: absolute;
    inset: 17% 13% 10%;
    z-index: -1;
    border-radius: 50%;
    background: radial-gradient(circle at 70% 28%, rgba(255,255,255,.34), transparent 33%);
}
.paint-drop-character__smile {
    position: absolute;
    left: 50%;
    top: 62%;
    width: 25%;
    height: 15%;
    border: 3px solid #08291f;
    border-top: 0;
    border-left-color: transparent;
    border-right-color: transparent;
    border-radius: 0 0 50% 50%;
    transform: translateX(-50%);
    transition: width .2s ease, height .2s ease, top .2s ease;
}
.paint-drop-character.is-curious {
    filter: saturate(1.16) brightness(1.08);
    box-shadow: inset 16px 12px 24px rgba(255,255,255,.28), 0 0 0 9px rgba(185,229,27,.12), 0 26px 54px rgba(0,0,0,.3);
    animation: drop-curious .72s ease-in-out infinite alternate;
}
.paint-drop-character.is-curious .paint-drop-character__smile { width: 34%; height: 20%; top: 60%; }
.paint-drop-character.is-startled { animation: drop-pop .42s cubic-bezier(.2,.9,.25,1.3) 1 !important; }
@keyframes drop-idle { 0%,100% { margin-top: 0; } 50% { margin-top: -7px; } }
@keyframes drop-curious { from { margin-top: -5px; } to { margin-top: -15px; } }
@keyframes drop-pop { 0%,100% { scale: 1; } 45% { scale: 1.18 .84; } 72% { scale: .92 1.12; } }

@media (max-width: 768px) {
    .paint-can.paint-can--real { width: 285px !important; left: -12% !important; top: -1% !important; }
    .paint-can__brand-overlay { width: 18.5%; }
    .paint-drop-character { right: 3% !important; top: 48% !important; }
}
@media (max-width: 420px) {
    .paint-can.paint-can--real { width: 260px !important; left: -15% !important; }
}
@media (prefers-reduced-motion: reduce) {
    .paint-can.paint-can--real, .paint-drop-character { animation: none !important; }
}

/* 2026 final experience pass: stable responsive layout, no rejected props/arcs. */
html, body { max-width: 100%; overflow-x: clip; }
.paint-roller,
.paint-roller--real,
.paint-can__brand-overlay { display: none !important; }
.paint-can.paint-can--real { left: -8% !important; }
.logo-circle::before,
.logo-circle::after,
.opening-motion__logo::before,
.opening-motion__logo::after { content: none !important; display: none !important; }
#products { overflow-anchor: none; }

.brand-story-section { padding: clamp(3.5rem, 7vw, 6rem) 0; background: #071d17; color: white; }
.brand-story-card { width: min(1180px, 100%); margin: auto; display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(280px, .55fr); gap: clamp(1.25rem, 4vw, 3rem); align-items: center; }
.brand-story-carousel { position: relative; min-width: 0; border-radius: 28px; overflow: hidden; background: #0b2d24; box-shadow: 0 28px 70px rgba(0,0,0,.35); isolation: isolate; }
.brand-story-carousel::after { content: ""; position: absolute; z-index: 2; inset: -35% -65%; pointer-events: none; background: linear-gradient(112deg, transparent 40%, rgba(255,255,255,.16) 49%, transparent 58%); transform: translate3d(-28%,0,0); animation: brand-story-sheen 8.8s ease-in-out infinite; }
.brand-story-track { position: relative; width: 100%; aspect-ratio: 16 / 9; overflow: hidden; background: #0b2d24; isolation: isolate; }
.brand-story-media { position: absolute; z-index: 0; inset: 0; display: block; width: 100%; height: 100%; padding: 0; border: 0; background: #0b2d24; cursor: zoom-in; opacity: 0; pointer-events: none; transform: translateZ(0); transition: opacity 1.3s cubic-bezier(.4,0,.2,1); will-change: opacity; backface-visibility: hidden; }
.brand-story-media.is-leaving { z-index: 1; opacity: 0; }
.brand-story-media.is-active { z-index: 2; opacity: 1; pointer-events: auto; }
.brand-story-media img { display: block; width: 100%; height: 100%; aspect-ratio: 16 / 9; object-fit: cover; transform: scale(1.065) translate3d(1.2%,0,0); filter: saturate(1.02) contrast(1.01); will-change: transform, filter; backface-visibility: hidden; }
.brand-story-media.is-active img,
.brand-story-media.is-leaving img { animation: brand-story-cinematic 6.6s linear both; }
.brand-story-media.is-active:hover img { filter: saturate(1.09) contrast(1.025); }
.brand-story-media:focus-visible { outline: 3px solid #d9f78a; outline-offset: -6px; }
.brand-story-arrow { position: absolute; z-index: 3; top: 50%; width: 46px; height: 46px; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.46); border-radius: 999px; color: white; background: rgba(4,29,22,.72); box-shadow: 0 10px 28px rgba(0,0,0,.24); backdrop-filter: blur(9px); transform: translateY(-50%); transition: background .2s ease, transform .2s ease; }
.brand-story-arrow:hover { background: rgba(15,107,70,.94); transform: translateY(-50%) scale(1.06); }
.brand-story-arrow:focus-visible { outline: 3px solid #d9f78a; outline-offset: 2px; }
.brand-story-arrow--prev { right: 14px; }
.brand-story-arrow--next { left: 14px; }
@keyframes brand-story-cinematic { from { transform: scale(1.065) translate3d(1.2%,0,0); filter: saturate(1.02) contrast(1.01); } to { transform: scale(1.01) translate3d(-.35%,0,0); filter: saturate(1.08) contrast(1.025); } }
@keyframes brand-story-sheen { 0%, 62% { transform: translate3d(-28%,0,0); opacity: 0; } 70% { opacity: .7; } 82%, 100% { transform: translate3d(28%,0,0); opacity: 0; } }
.brand-story-kicker { margin: 0 0 .7rem; color: #b9e51b; font-weight: 900; }
.brand-story-copy h2 { margin: 0 0 1rem; font-size: clamp(1.9rem, 4vw, 3.7rem); line-height: 1.12; }
.brand-story-copy > p:not(.brand-story-kicker) { color: rgba(255,255,255,.74); line-height: 1.9; }
.brand-story-actions { display: flex; flex-wrap: wrap; gap: .65rem; margin-top: 1.35rem; }
.brand-story-actions a { min-height: 46px; display: inline-flex; align-items: center; padding: .65rem 1rem; border-radius: 999px; color: #08291f; background: #b9e51b; font-weight: 850; }
.brand-story-actions a + a { color: white; border: 1px solid rgba(255,255,255,.32); background: transparent; }

.paint-studio { padding: clamp(4rem, 8vw, 7rem) 0; background: linear-gradient(145deg, #edf7e3, #f9fcf4); color: #153d2b; }
.paint-studio-head { max-width: 760px; margin: 0 auto clamp(2rem, 5vw, 3.4rem); text-align: center; }
.paint-studio-head > p { margin: 0 0 .4rem; color: #39752e; font-weight: 900; }
.paint-studio-head h2 { margin: 0 0 .75rem; font-size: clamp(2rem, 5vw, 3.6rem); line-height: 1.15; }
.paint-studio-head span { color: #5e7266; }
.paint-studio-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 1.2rem; align-items: stretch; }
.paint-tool-card { min-width: 0; padding: clamp(1.15rem, 2.5vw, 1.75rem); border: 1px solid rgba(44,107,67,.15); border-radius: 24px; background: rgba(255,255,255,.88); box-shadow: 0 20px 55px rgba(27,88,53,.09); }
.paint-tool-icon { width: 48px; height: 48px; display: grid; place-items: center; margin-bottom: 1rem; border-radius: 16px; color: #0a3d2b; background: #b9e51b; }
.paint-tool-card h3 { margin: 0 0 1rem; font-size: 1.25rem; }
.paint-tool-fields { display: grid; grid-template-columns: 1fr 1fr; gap: .65rem; }
.paint-tool-card label { display: grid; gap: .35rem; color: #496355; font-size: .84rem; font-weight: 750; }
.paint-tool-card input,
.paint-tool-card select { width: 100%; min-height: 44px; padding: .55rem .65rem; border: 1px solid #cedbd2; border-radius: 12px; color: #153d2b; background: white; font: inherit; }
.paint-coats-field { grid-column: 1 / -1; }
.paint-coats-stepper { display: grid; grid-template-columns: 48px minmax(0, 1fr) 48px; gap: .5rem; direction: ltr; }
.paint-coats-stepper button { min-height: 44px; border: 1px solid #b9cfbd; border-radius: 12px; color: #0b3d2d; background: #eff8e9; font-size: 1.45rem; font-weight: 900; line-height: 1; cursor: pointer; transition: transform .15s ease, background-color .15s ease; }
.paint-coats-stepper button:hover:not(:disabled) { transform: translateY(-1px); background: #dff0c9; }
.paint-coats-stepper button:focus-visible { outline: 3px solid rgba(185,229,27,.55); outline-offset: 2px; }
.paint-coats-stepper button:disabled { opacity: .45; cursor: not-allowed; }
.paint-coats-stepper #paint-coats { text-align: center; direction: rtl; font-weight: 850; }
.paint-tool-result { min-height: 76px; display: grid; align-content: center; gap: .25rem; margin-top: 1rem; padding: .8rem 1rem; border-radius: 15px; color: #eaffc9; background: #0b3d2d; }
.paint-tool-result strong { font-size: 1.16rem; }
.paint-tool-result span { font-size: .78rem; color: rgba(255,255,255,.68); }
.color-room-preview { --room-wall: #f3ead8; position: relative; height: 190px; overflow: hidden; border-radius: 16px; background: linear-gradient(90deg, rgba(0,0,0,.1), transparent 36%), var(--room-wall); transition: background .35s ease; }
.color-room-preview > span { position: absolute; inset: 0; z-index: 0; pointer-events: none; opacity: 0; transition: opacity .28s ease, filter .28s ease; }
.color-room-preview[data-texture="granite"] > span { opacity: .58; background: radial-gradient(circle at 12% 22%, rgba(255,255,255,.75) 0 1px, transparent 1.8px), radial-gradient(circle at 72% 66%, rgba(5,24,17,.55) 0 1.2px, transparent 2px), radial-gradient(circle at 42% 38%, rgba(88,76,60,.48) 0 .8px, transparent 1.7px); background-size: 13px 13px, 17px 17px, 9px 9px; mix-blend-mode: multiply; filter: contrast(1.25); }
.color-room-preview[data-texture="stone"] > span { opacity: .7; background: repeating-linear-gradient(12deg, rgba(255,255,255,.14) 0 2px, transparent 2px 7px), radial-gradient(ellipse at 20% 36%, rgba(0,0,0,.2), transparent 16%), radial-gradient(ellipse at 76% 68%, rgba(255,255,255,.23), transparent 19%), repeating-radial-gradient(circle at 30% 40%, rgba(20,35,26,.15) 0 1px, transparent 1px 6px); background-size: auto, 90px 48px, 110px 62px, 18px 14px; mix-blend-mode: overlay; filter: contrast(1.45); }
.color-room-preview::before { content: ''; position: absolute; z-index: 1; left: 12%; right: 12%; bottom: 16%; height: 27%; border-radius: 18px 18px 3px 3px; background: #d6b99a; box-shadow: 0 20px 0 -11px #8b725e; }
.color-room-preview::after { content: ''; position: absolute; z-index: 1; width: 22%; height: 42%; right: 10%; top: 12%; border: 9px solid #f4ecdc; background: linear-gradient(150deg,#b8d8e8,#f2ca9b); box-shadow: 0 8px 22px rgba(0,0,0,.14); }
.color-swatches { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .85rem; }
.color-swatches button { width: 38px; height: 38px; border: 3px solid white; border-radius: 50%; background: var(--swatch); box-shadow: 0 0 0 1px #cbd7ce; transition: transform .18s ease, box-shadow .18s ease; }
.color-swatches button.active { transform: scale(1.13); box-shadow: 0 0 0 3px #173f2c; }
.selected-color-name { margin: .65rem 0 0; color: #496355; font-weight: 800; }
.catalog-color-controls { display: grid; grid-template-columns: 1fr 1fr; gap: .55rem; margin-top: .85rem; }
.color-visualizer-card [hidden] { display: none !important; }
.color-visualizer-card .catalog-color-controls > label:not([hidden]),
.color-visualizer-card #visualizer-code-step:not([hidden]),
.color-visualizer-card #catalog-color-picker:not([hidden]),
.color-visualizer-card #visualizer-texture-step:not([hidden]),
.color-visualizer-card #selected-color-name:not([hidden]) { animation: studio-step-in .28s ease both; }
@keyframes studio-step-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.catalog-color-picker { position: relative; margin-top: .75rem; padding: .5rem; border: 1px solid #d5e2d8; border-radius: 14px; background: #f5f8f4; }
.catalog-color-picker canvas { display: block; width: 100%; max-height: 260px; object-fit: contain; border-radius: 10px; cursor: crosshair; touch-action: none; }
.catalog-color-picker p { margin: .45rem .2rem 0; color: #5f7366; font-size: .73rem; text-align: center; }
.catalog-color-lens { --picked-color: #fff; position: absolute; z-index: 4; width: 48px; height: 48px; border: 5px solid white; border-radius: 50%; background: var(--picked-color); box-shadow: 0 0 0 2px #153d2b, 0 8px 22px rgba(0,0,0,.24); pointer-events: none; opacity: 0; transform: translate(-50%,-135%); transition: opacity .15s ease; }
.catalog-color-lens.active { opacity: 1; }
.color-picker-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: .55rem; margin-top: .75rem; }
.color-picker-actions button { min-height: 43px; border: 1px solid #b9cbbd; border-radius: 12px; color: #153d2b; background: white; font: inherit; font-weight: 800; }
.color-picker-actions button:hover { border-color: #0f6b46; background: #eff8e9; }
.texture-picker { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .45rem; margin-top: .75rem; padding: .7rem; border: 1px solid #d6e2d9; border-radius: 14px; }
.texture-picker legend { padding: 0 .35rem; color: #496355; font-size: .78rem; font-weight: 850; }
.texture-picker button { min-width: 0; min-height: 68px; display: grid; place-items: center; gap: .25rem; padding: .4rem; border: 1px solid #d2ddd5; border-radius: 11px; color: #365445; background: white; font: inherit; font-size: .7rem; font-weight: 800; }
.texture-picker button[hidden] { display: none !important; }
.texture-picker button > span { width: 32px; height: 32px; border-radius: 9px; background: #d5dfca; box-shadow: inset 0 0 0 1px rgba(0,0,0,.07); }
.texture-picker button[data-texture="granite"] > span { background: radial-gradient(circle,#315143 0 1px,transparent 1.7px),radial-gradient(circle,#fff 0 1px,transparent 1.7px),#d5dfca; background-position: 0 0,4px 5px; background-size: 8px 8px,9px 9px; }
.texture-picker button[data-texture="stone"] > span { background: repeating-linear-gradient(13deg,rgba(255,255,255,.35) 0 2px,transparent 2px 6px),repeating-radial-gradient(circle,#53685d 0 1px,#aab8af 1px 5px); }
.texture-picker button.active { border-color: #0f6b46; color: #0b3d2d; background: #eff8e9; box-shadow: 0 0 0 2px rgba(15,107,70,.13); }
.product-advisor-card > label + label { margin-top: .75rem; }
.advisor-whatsapp { min-height: 48px; display: flex; align-items: center; justify-content: center; gap: .55rem; margin-top: .8rem; border-radius: 14px; color: white; background: #188b4a; font-weight: 850; }
.paint-studio-note { margin: 1.2rem 0 0; text-align: center; color: #617668; font-size: .78rem; }

@media (max-width: 1024px) {
    #about, #products, #projects, #catalogs, #contact, #delivery { content-visibility: visible !important; contain-intrinsic-size: none !important; }
    #products .fade-in-up, #products .animate__animated { opacity: 1 !important; transform: none !important; animation: none !important; }
    .paint-studio-grid { grid-template-columns: 1fr 1fr; }
    .product-advisor-card { grid-column: 1 / -1; }
    .paint-hero.gradient-bg { background-attachment: scroll !important; }
}

@media (max-width: 768px) {
    section { scroll-margin-top: 74px; }
    .paint-hero__grid { display: grid !important; grid-template-columns: minmax(0,1fr) !important; }
    .paint-hero__stage { min-height: 330px !important; overflow: hidden; border-radius: 26px; }
    .paint-can.paint-can--real { width: min(88vw, 330px) !important; left: 0 !important; top: 0 !important; transform: rotateZ(-2deg) !important; }
    .paint-drop-character { right: 4% !important; top: 56% !important; }
    .brand-story-card, .paint-studio-grid { grid-template-columns: 1fr; }
    .brand-story-copy { order: -1; }
    .brand-story-carousel { border-radius: 18px; }
    .brand-story-arrow { width: 42px; height: 42px; }
    .brand-story-arrow--prev { right: 8px; }
    .brand-story-arrow--next { left: 8px; }
    .product-advisor-card { grid-column: auto; }
    .paint-tool-fields { grid-template-columns: 1fr 1fr; }
    .catalog-image-viewport .catalog-fullsize-image { max-width: 94%; max-height: 84%; }
}

@media (max-width: 420px) {
    .paint-hero__stage { min-height: 300px !important; }
    .paint-can.paint-can--real { width: 300px !important; }
    .paint-tool-fields { grid-template-columns: 1fr; }
    .catalog-color-controls { grid-template-columns: 1fr; }
    .texture-picker { grid-template-columns: 1fr; }
    .texture-picker button { grid-template-columns: 34px 1fr; justify-items: start; min-height: 52px; }
    .brand-story-actions { display: grid; }
    .brand-story-actions a { width: 100%; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
    .brand-story-media,
    .brand-story-media img,
    .brand-story-carousel::after { animation: none !important; transition: none !important; }
}

/* Highest-priority final overrides. */
html, body, button, input, select, textarea,
h1, h2, h3, h4, h5, h6 { font-family: 'Cairo', sans-serif !important; }
.header-logo, .footer-logo, .logo-circle, .opening-motion__logo {
    background: transparent url('/brand-logo-clean-v4.png') center / contain no-repeat !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    filter: drop-shadow(0 0 2px rgba(255,255,255,1)) drop-shadow(0 0 6px rgba(255,255,255,.72)) drop-shadow(0 9px 15px rgba(0,0,0,.3)) saturate(1.08) !important;
}
.catalog-image-content {
    height: min(98svh, 980px) !important;
    display: grid !important;
    grid-template-rows: auto auto minmax(0, 1fr) auto !important;
    overflow: hidden !important;
}
.catalog-image-viewport {
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    display: grid !important;
    place-items: center !important;
    overflow: hidden !important;
    touch-action: none !important;
}
.catalog-image-viewport .catalog-fullsize-image {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: contain !important;
    object-position: center !important;
    margin: 0 !important;
    touch-action: none !important;
}
@media (max-width: 768px) {
    .catalog-image-content { width: 100vw !important; height: 100svh !important; max-height: 100svh !important; }
    .catalog-image-viewport { width: calc(100vw - .8rem) !important; height: auto !important; min-height: 0 !important; }
}
