    @layer base, components, utilities;

    @layer base {
      @font-face {
        font-family: "Vazirmatn Variable";
        font-style: normal;
        font-display: swap;
        font-weight: 100 900;
        src: url("/assets/Vazirmatn-RD[wght].woff2") format(woff2);
      }

      @property --ai-angle {
        syntax: "<angle>";
        initial-value: 0deg;
        inherits: false;
      }

      :root {
        --bg: #e5edf5;
        --shadow-dark: rgba(95, 157, 231, 0.45);
        --shadow-light: rgba(255, 255, 255, 0.9);
        --text-primary: #2d3748;
        --text-secondary: #879fbe;
        --accent-darken: #c95e00;
        --accent: #e75a08;
        --radius: 24px;
        --transition: 0.4s ease-in-out;
        --raised: -8px -8px 16px var(--shadow-light), 8px 8px 16px var(--shadow-dark);
        --hero: -15px -15px 30px var(--shadow-light), 15px 15px 30px var(--shadow-dark);
        --subtle: -4px -4px 8px var(--shadow-light), 4px 4px 8px var(--shadow-dark);
        --pressed: inset 6px 6px 12px var(--shadow-dark), inset -6px -6px 12px var(--shadow-light);
        --pressed-deep: inset 10px 10px 20px var(--shadow-dark), inset -10px -10px 20px var(--shadow-light);
        --morph-open-dur: 450ms;
        --morph-close-dur: 350ms;
        --morph-ease: cubic-bezier(0.34, 1.3, 0.64, 1);
        --morph-close-ease: cubic-bezier(0.25, 1, 0.5, 1);
        --tl-path-len: 678;
        color-scheme: light;
        font-family: 'Vazirmatn Variable', system-ui, sans-serif;
        font-size: 15px;
        font-weight: 400;
        background-color: var(--bg);
      }

      :focus-visible {
        outline: 2px solid var(--accent);
        outline-offset: 2px;
      }

      body {
        display: flex;
        flex-direction: column;
        height: 100svh;
        timeline-scope: --services-track, --section-landing, --section-services, --section-products, --section-footer;
        color: var(--text-primary);
        margin: 0;
        overflow: hidden;
      }

      main {
        container-type: inline-size;
        container-name: main-container;
        overflow-y: scroll;
        scroll-snap-type: y proximity;
        scroll-behavior: smooth;
        display: flex;
        flex-direction: column;
        flex-wrap: nowrap;
        width: 100%;
        scrollbar-color: var(--accent-darken) transparent;
        scroll-padding-block: 3rem;
        padding-block-start: 3rem;
        align-items: center;
      }

      h2 {
        font-size: clamp(2rem, 2.8vw, 4rem);
        text-align: center;
        font-weight: 700;
        text-wrap: balance;
      }

      h3 {
        font-size: 1rem;
        margin-bottom: 0;
        color: var(--text-primary);
        font-weight: 600;
      }

      p {
        line-height: 1.8;
        color: var(--text-secondary);
        padding: 0 1rem;
        text-wrap: pretty;
      }
    }

    @layer components {
      header {
        position: fixed;
        top: 1.3rem;
        left: 50%;
        transform: translateX(-50%);
        z-index: 10;
        width: fit-content;
      }

      nav {
        display: flex;
        background-color: var(--bg);
        border-radius: 40px;
        box-shadow: var(--raised);
        border: 2px solid rgba(255, 255, 255, 0.4);
        align-items: center;
        padding: 0.3rem 0.6rem;
      }
      nav ul {
        display: flex;
        list-style: none;
        margin: 0;
        padding: 0;
        gap: 0.25rem;
      }

      nav a {
        text-decoration: none;
        color: var(--text-secondary);
        font-weight: bold;
        font-size: 0.85rem;
        padding: 0.6rem 1.2rem;
        border-radius: 30px;
        transition: var(--transition);
        display: block;
      }
      nav a:hover {
        color: var(--accent);
      }

      #landing    { view-timeline-name: --section-landing; }
      #services   { view-timeline-name: --section-services; }
      #products   { view-timeline-name: --section-products; }
      #footer-section { view-timeline-name: --section-footer; }

      @supports (animation-timeline: view()) {
        nav a {
          animation: nav-active 1s linear both;
          animation-timeline: var(--section-timeline);
          animation-range: entry 45% exit 0%;
        }
      }

      @keyframes nav-active {
        0%   { color: var(--text-secondary); box-shadow: none; }
        1%   { color: var(--accent); box-shadow: var(--pressed); }
        99%  { color: var(--accent); box-shadow: var(--pressed); }
        100% { color: var(--text-secondary); box-shadow: none; }
      }

      main > section,
      main > footer {
        display: flex;
        width: min(90vw, 900px);
        scroll-snap-align: start;
        box-sizing: border-box;
        gap: 2rem;
        flex-direction: column;
        align-items: center;
        min-height: 100svh;
        padding: 2.5rem 1.5rem;
        margin: 0 auto;
        flex-shrink: 0;
        content-visibility: auto;
        contain-intrinsic-size: auto 100svh;
      }

      #footer-section {
        min-height: fit-content;
        margin-top: 4rem;
        margin-bottom: 4rem;
      }

      .accent-text { color: var(--accent); }

      .btn {
        background-color: var(--bg);
        color: var(--text-primary);
        border: 2px solid rgb(255 255 255 / 15%);
        padding: 0.8rem 1.2rem;
        border-radius: 18px;
        box-shadow: var(--raised);
        font-weight: 500;
        cursor: pointer;
        transition: var(--transition);
        display: inline-flex;
        text-decoration: none;
        font-family: inherit;
        font-size: 0.95em;
        width: fit-content;
        justify-content: center;
        white-space: nowrap;
        align-items: center;
      }
      .btn:hover { color: var(--accent-darken); transform: translateY(-2px); }
      .btn:active, .btn:focus { box-shadow: var(--pressed); transform: translateY(0); }

      .landing-headline { display: flex; flex-direction: column; align-items: center; gap: 0.75rem; width: 100%; text-align: center; margin: 0 0 1.5rem 0; }
      .fixed-part { display: block; width: 100%; text-align: center; color: var(--text-primary); font-weight: 800; font-size: clamp(1.5rem, 4vw, 3.2rem); line-height: 1.4; text-wrap: balance; }
      .dynamic-part-wrapper { display: grid; width: 100%; place-items: center; }
      .dynamic-text-item { grid-area: 1 / 1; width: 100%; color: var(--accent); font-weight: 800; font-size: clamp(1.2rem, 3vw, 2.2rem); opacity: 0; animation: text-rotate 12.6s infinite ease-in-out; line-height: 1.5; text-align: center; text-wrap: balance; }
      .dynamic-text-item:nth-child(1) { animation-delay: 0s; }
      .dynamic-text-item:nth-child(2) { animation-delay: 4.2s; }
      .dynamic-text-item:nth-child(3) { animation-delay: 8.4s; }

      @keyframes text-rotate {
        0% { opacity: 0; transform: translateY(15px) scale(0.92); }
        4% { opacity: 1; transform: translateY(0) scale(1); }
        29.33% { opacity: 1; transform: translateY(0) scale(1); }
        33.33% { opacity: 0; transform: translateY(-15px) scale(0.92); }
        100% { opacity: 0; transform: translateY(15px) scale(0.92); }
      }

      #landing { flex-direction: row; }
      #landing img { width: min(75vw, 275px); height: auto; filter: drop-shadow(rgba(95,157,231,0.45) 10px 10px 14px) drop-shadow(rgb(255,255,255) -10px -10px 14px); background: url(/assets/map-art.svg) center center / 100% 100%; aspect-ratio: 1; object-fit: contain; flex: 1; }
      .hero-text { display: flex; flex: 2; gap: 1rem; align-items: center; justify-content: center; align-content: flex-start; flex-wrap: wrap; }
      .hero-text .actions { gap: 1.4rem; display: flex; }

      .products-grid { display: flex; gap: 3.5rem; width: 100%; flex-wrap: wrap; justify-content: center; }
      .product-card { background: var(--bg); padding: 0 0 2rem; border-radius: var(--radius); box-shadow: var(--raised); transition: var(--transition); text-align: center; display: flex; flex-direction: column; align-items: center; cursor: pointer; border: 1px solid rgba(255,255,255,0.3); position: relative; max-width: 280px; flex: 280px; align-content: center; justify-content: space-between; content-visibility: auto; contain-intrinsic-size: 500px; }
      .product-icon { width: 100%; height: auto; margin: 0; display: flex; align-items: center; justify-content: center; border-radius: 22px; overflow: hidden; border: 2px #e5edf5 solid; }
      .product-icon img { width: 100%; height: 100%; object-fit: cover; }

      .product-cta { position: relative; isolation: isolate; display: inline-flex; align-items: center; justify-content: center; padding: 0.8rem 1.6rem; border-radius: 16px; background-color: var(--bg); box-shadow: var(--raised); transition: background-color var(--transition), color var(--transition), transform var(--transition); cursor: pointer; color: var(--text-primary); font-family: inherit; font-weight: 700; overflow: visible; border: none; }
      .product-cta::before { content: ''; position: absolute; inset: -1.5px; padding: 2px; border-radius: 19px; background: conic-gradient(from var(--ai-angle), #ffbc00 0deg, rgb(229 237 245) 90deg, #ffffff 180deg, #e5edf5 270deg, #ffbc00 360deg); mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0); mask-composite: exclude; z-index: -1; animation: rotate-border 5s linear infinite; }
      .product-cta:hover, .product-cta:focus { background-color: var(--accent); color: white; }
      .product-cta:active { box-shadow: var(--pressed); transform: translateY(2px); }

      @keyframes rotate-border { to { --ai-angle: 360deg; } }

      .footer-card { background: var(--bg); padding: 2rem 1rem; border-radius: 40px; box-shadow: var(--pressed-deep); text-align: center; border: 1px solid rgba(255,255,255,0.5); }
      .newsletter { display: flex; gap: 1.5rem; max-width: 500px; margin: 2rem auto; justify-content: center; align-items: center; flex-wrap: wrap; width: 100%; }
      .newsletter input { flex: 1; padding: 1rem 1.5rem; border-radius: 18px; border: none; background: var(--bg); box-shadow: var(--pressed); outline: none; transition: var(--transition); field-sizing: content; font-family: inherit;}
      .newsletter input:focus { box-shadow: var(--pressed-deep); }

      .contact-info-card {
        display: flex;
        flex-wrap: wrap;
        gap: 1.5rem 2.5rem;
        justify-content: center;
        align-items: flex-start;
        background: var(--bg);
        border-radius: 24px;
        box-shadow: var(--raised);
        border: 1px solid rgba(255, 255, 255, 0.35);
        padding: 1.8rem 2.2rem;
        margin: 0.5rem auto 0;
        max-width: 650px;
        width: fit-content;
      }

      .contact-item {
        display: flex;
        align-items: center;
        gap: 0.7rem;
        color: var(--text-primary);
        text-decoration: none;
        font-size: 0.92rem;
        font-weight: 500;
        transition: var(--transition);
        padding: 0.4rem 0.8rem;
        border-radius: 14px;
        white-space: nowrap;
      }
      .contact-item:hover {
        color: var(--accent);
        box-shadow: var(--subtle);
      }

      .contact-icon {
        flex-shrink: 0;
        width: 40px;
        height: 40px;
        border-radius: 12px;
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: var(--subtle);
        color: var(--accent);
      }

      .contact-label {
        font-size: 0.72rem;
        color: var(--text-secondary);
        display: block;
        line-height: 1.3;
      }
      .contact-value {
        font-size: 0.92rem;
        color: var(--text-primary);
        font-weight: 600;
        line-height: 1.4;
        direction: ltr;
        display: block;
      }

      .social-links { display: flex; gap: 1.5rem; margin: 1.5rem auto 0.5rem; list-style: none; padding: 0; }
      .social-btn { width: 60px; height: 60px; border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: var(--raised); color: var(--text-secondary); transition: var(--transition); text-decoration: none; }
      .social-btn:hover, .social-btn:focus { box-shadow: var(--pressed); color: var(--accent); transform: scale(0.9); }

      ::view-transition-group(support-morph) { animation-duration: var(--morph-open-dur); animation-timing-function: var(--morph-ease); }
      ::view-transition-old(support-morph) { animation: morph-fade-out var(--morph-open-dur) var(--morph-ease) both; mix-blend-mode: normal; backface-visibility: hidden; height: 100%; width: 100%; }
      ::view-transition-new(support-morph) { animation: morph-fade-in var(--morph-open-dur) var(--morph-ease) both; mix-blend-mode: normal; backface-visibility: hidden; height: 100%; width: 100%; }

      @keyframes morph-fade-out { 0% { opacity: 1; } 100% { opacity: 0; } }
      @keyframes morph-fade-in { 0% { opacity: 0; } 100% { opacity: 1; } }

      body.is-morphing * { animation-play-state: paused !important; pointer-events: none !important; }

      #ai-agent-btn { position: fixed; bottom: 2rem; left: 2rem; width: 55px; height: 55px; border-radius: 50%; background-color: var(--bg); box-shadow: var(--raised); border: 1px solid rgba(255,255,255,0.4); z-index: 999; display: grid; place-items: center; cursor: pointer; padding: 0; margin: 0; outline: none; transition: transform 0.2s ease; }
      #ai-agent-btn::before { content: ''; position: absolute; inset: -2px; padding: 2.5px; border-radius: inherit; background: conic-gradient(from var(--ai-angle), #ffbc00 0deg, rgb(229 237 245) 90deg, #ffffff 180deg, #e5edf5 270deg, #ffbc00 360deg); mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0); mask-composite: exclude; animation: rotate-border 5s linear infinite; z-index: -1; pointer-events: none; }
      #ai-agent-btn:hover { transform: scale(1.05); }
      #ai-agent-btn:active { box-shadow: var(--pressed); transform: scale(0.95); }

      #support-morph-container { position: fixed; z-index: 1000; background-color: var(--bg); border: 1px solid rgba(255,255,255,0.4); display: none; flex-direction: column; overflow: hidden; box-sizing: border-box; }
      #support-morph-container::before { content: ''; position: absolute; inset: -3px; padding: 3px; border-radius: inherit; background: conic-gradient(from var(--ai-angle), #ffb600 0deg, rgb(229 237 245) 90deg, #ffffff 180deg, #e5edf5 270deg, #ff8d00 360deg); mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0); mask-composite: exclude; animation: rotate-border 5s linear infinite; z-index: -1; pointer-events: none; }

      .chat-dialog-center { top: 50%; left: 50%; transform: translate(-50%, -50%); width: min(calc(100vw - 40px), 420px); height: min(calc(100vh - 100px), 550px); border-radius: 24px; box-shadow: var(--hero); }
      .chat-dialog-auth { top: 50%; left: 50%; transform: translate(-50%, -50%); width: min(calc(100vw - 40px), 360px); height: 410px; border-radius: 24px; box-shadow: var(--hero); }
      .chat-dialog-fab { bottom: 2rem; left: 2rem; width: min(calc(100vw - 40px), 380px); height: min(calc(100vh - 100px), 520px); border-radius: 24px; box-shadow: var(--hero); }

      #auth-window-content, #chat-window-content { display: none; flex-direction: column; width: 100%; height: 100%; box-sizing: border-box; }
      .chat-header { padding: 1.5rem; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid rgba(255,255,255,0.2); }
      .chat-messages { flex: 1; padding: 1.2rem; overflow-y: auto; display: flex; flex-direction: column; gap: 1.2rem; scrollbar-color: var(--accent-darken) var(--bg); scrollbar-width: thin; }
      .chat-bubble { padding: 0.8rem 1.2rem; border-radius: 18px; max-width: 80%; font-size: 0.9rem; box-shadow: var(--subtle); line-height: 1.7; word-wrap: break-word; }
      .chat-bubble.ai { align-self: flex-start; color: var(--text-primary); border: 1px rgb(255 255 255 / 50%) solid; border-bottom-left-radius: 4px; background-color: var(--bg); }
      .chat-bubble.user { align-self: flex-end; background-color: var(--accent); color: white; border-bottom-right-radius: 4px; }
      .chat-bubble strong.accent-text { color: var(--accent); }

      .chat-input-area { padding: 1rem; display: flex; gap: 0.5rem; width: 100%; box-sizing: border-box; }
      .chat-input-area input { flex: 1; padding: 0.8rem; border-radius: 15px; border: none; background: var(--bg); box-shadow: var(--pressed); outline: none; font-family: inherit; color: var(--text-primary); }

      .auth-input { width: 100%; box-sizing: border-box; padding: 1rem; margin-bottom: 1rem; border-radius: 15px; border: none; background: var(--bg); box-shadow: var(--pressed); outline: none; font-family: inherit; color: var(--text-primary); transition: var(--transition); }
      .auth-input:focus { box-shadow: var(--pressed-deep); }

      .typing-indicator { display: flex; align-items: center; gap: 4px; padding: 4px 8px; }
      .typing-indicator span { width: 8px; height: 8px; background-color: var(--accent); border-radius: 50%; display: inline-block; animation: typing-bounce 1.4s infinite ease-in-out both; }
      .typing-indicator span:nth-child(1) { animation-delay: -0.32s; }
      .typing-indicator span:nth-child(2) { animation-delay: -0.16s; }

      @keyframes typing-bounce { 0%, 80%, 100% { transform: scale(0); } 40% { transform: scale(1); } }

      .services-layout { view-timeline: --services-track block; display: flex; flex-direction: row; align-items: flex-start; width: 100%; gap: 1.5rem; justify-content: center; position: relative; }
      .services-timeline { width: 60px; flex-shrink: 0; position: sticky; top: max(15svh, 100px); }
      .services-cards { flex: 1; display: flex; flex-direction: column; gap: 0; max-width: 600px; padding: 0; }
      .service-item { min-height: 160px; display: flex; align-items: center; box-sizing: border-box; scroll-snap-align: center; }
      .service-card-new { background: var(--bg); border-radius: 20px; box-shadow: var(--raised); border: 1px solid rgba(255,255,255,0.4); padding: 1.2rem 1.4rem; transition: box-shadow var(--transition), transform var(--transition); width: 100%; }
      .service-card-new:hover { box-shadow: var(--hero); transform: translateX(-3px); }
      .service-card-new h3 { margin: 0 0 0.35rem; font-size: 1.05rem; }
      .service-card-new p { margin: 0; font-size: 0.88rem; line-height: 1.75; padding: 0; }

      .timeline-svg { width: 60px; height: 800px; display: block; overflow: visible; }
      .timeline-liquid { stroke-dasharray: var(--tl-path-len); stroke-dashoffset: var(--tl-path-len); }
      .tl-icon { opacity: 1; transform: scale(0.72); transform-box: fill-box; transform-origin: center; will-change: transform, opacity; }

      @supports ((animation-timeline: view()) and (animation-range: entry)) {
        .service-item { animation: elegant-reveal cubic-bezier(0.16, 1, 0.3, 1) both; animation-timeline: view(); animation-range: entry 25% cover 45%; }
        .timeline-liquid { animation: liquid-draw linear both; animation-timeline: --services-track; animation-range: entry 15% cover 65%; will-change: stroke-dashoffset; }
      }

      @supports not ((animation-timeline: view()) and (animation-range: entry)) {
        .timeline-liquid { stroke-dashoffset: 0; }
        .service-item { opacity: 1; transform: none; }
      }

      @keyframes elegant-reveal { from { opacity: 0; transform: translateY(60px) scale(0.92); filter: blur(8px); } to { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); } }
      @keyframes liquid-draw { 0% { stroke-dashoffset: var(--tl-path-len); } 100% { stroke-dashoffset: 0; } }

      @container main-container (max-width: 900px) {
        .services-layout { gap: 0.8rem; }
        .services-timeline { width: 60px; }
        .service-item { min-height: 160px; }
        .service-card-new { padding: 0.8rem 1rem; }
        .service-card-new h3 { font-size: 0.95rem; margin-bottom: 0.25rem; }
        .service-card-new p { font-size: 0.75rem; line-height: 1.5; }
        #landing { flex-direction: column; }
        #landing img { order: -1; }
        .newsletter { flex-direction: column; }
        .contact-info-card { flex-direction: column; align-items: center; gap: 1rem; padding: 1.5rem; }
      }
    }

    @layer utilities {
      .visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; pointer-events: none; }
      .fade-up { opacity: 0; transform: translateY(30px); animation: reveal both; animation-timeline: view(); animation-range: entry 10% cover 30%; }
      @keyframes reveal { to { opacity: 1; transform: translateY(0); } }
    }

    @media (prefers-reduced-motion: reduce) {
      *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
      .timeline-liquid { stroke-dashoffset: 0; }
      .tl-icon { transform: scale(0.72) !important; }
      ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
    }