/* ============================================
   Matodev — Global Stylesheet
   ============================================ */

/* Material Symbols */
.material-symbols-outlined {
    font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
    line-height: 1;
    flex-shrink: 0;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

/* Base Typography */
html {
    scroll-behavior: smooth;
    overflow-x: clip;
}

body {
    font-family: 'Manrope', sans-serif;
    color: #1a1c1c;
    background-color: #f9f9f9;
    min-width: 0;
    overflow-x: hidden;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
    font-family: 'Plus Jakarta Sans', sans-serif;
    overflow-wrap: anywhere;
}

p,
a,
button,
label,
input,
textarea,
select {
    overflow-wrap: break-word;
}

img,
picture,
svg,
video,
canvas,
iframe {
    display: block;
    max-width: 100%;
}

img,
video {
    height: auto;
}

button,
a,
input,
textarea,
select {
    touch-action: manipulation;
}

.grid > *,
.flex > * {
    min-width: 0;
}

/* Hero Gradient */
.hero-gradient {
    background: linear-gradient(135deg, #004432 0%, #155d47 100%);
}

/* Quality animation */
.quality-animation {
    position: relative;
    min-height: 16rem;
    overflow: hidden;
    border: 1px solid rgba(191, 201, 194, 0.45);
    border-radius: 1.5rem;
    background: linear-gradient(135deg, #004432 0%, #155d47 100%);
    box-shadow: 0 20px 40px rgba(21, 93, 71, 0.12);
    isolation: isolate;
}

.quality-animation__canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0.95;
}

.quality-animation__content {
    position: relative;
    z-index: 1;
    display: flex;
    min-height: 16rem;
    flex-direction: column;
    justify-content: space-between;
    padding: 1.5rem;
    color: #ffffff;
}

.quality-animation__icon {
    display: inline-flex;
    width: 3.5rem;
    height: 3.5rem;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(16px);
}

.quality-animation__icon .material-symbols-outlined {
    font-size: 2rem;
    font-variation-settings: 'FILL' 1, 'wght' 500, 'GRAD' 0, 'opsz' 24;
}

.quality-animation__metrics {
    display: grid;
    gap: 0.75rem;
}

.quality-animation__metrics span {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    color: rgba(255, 255, 255, 0.84);
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.quality-animation__metrics span::after {
    content: '';
    flex: 1;
    height: 0.375rem;
    max-width: 8rem;
    border-radius: 999px;
    background: linear-gradient(90deg, #acf1d4, rgba(255, 255, 255, 0.28));
}

/* Domain and language suggestion */
.domain-language-banner {
    position: fixed;
    right: 1.5rem;
    bottom: 1.5rem;
    z-index: 9997;
    width: min(32rem, calc(100vw - 3rem));
}

.domain-language-banner[hidden] {
    display: none;
}

.domain-language-banner__inner {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.25rem;
    border: 1px solid rgba(191, 201, 194, 0.45);
    border-radius: 1.25rem;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 20px 50px rgba(21, 93, 71, 0.16);
    backdrop-filter: blur(16px);
}

.domain-language-banner__title {
    margin: 0 0 0.25rem;
    color: #004432;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 800;
}

.domain-language-banner__text {
    margin: 0;
    color: #3f4944;
    font-size: 0.875rem;
    line-height: 1.55;
}

.domain-language-banner__actions {
    display: flex;
    flex-shrink: 0;
    gap: 0.5rem;
}

.domain-language-banner__primary,
.domain-language-banner__secondary {
    min-height: 44px;
    border-radius: 0.75rem;
    padding: 0.75rem 1rem;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.875rem;
    font-weight: 700;
    text-align: center;
    transition: opacity 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.domain-language-banner__primary {
    background: #004432;
    color: #ffffff;
}

.domain-language-banner__primary:hover {
    opacity: 0.86;
}

.domain-language-banner__secondary {
    border: 0;
    background: #e8e8e8;
    color: #1a1c1c;
    cursor: pointer;
}

.domain-language-banner__secondary:hover {
    background: #dadada;
}

/* Selection */
::selection {
    background-color: #acf1d4;
    color: #002116;
}

/* Header */
.site-mobile-menu {
    display: none;
    border-top: 1px solid rgba(191, 201, 194, 0.35);
}

.site-mobile-menu.is-open {
    display: block;
}

.site-mobile-menu a,
.mobile-menu-toggle {
    min-height: 44px;
}

@media (min-width: 768px) {
    .site-mobile-menu {
        display: none !important;
    }
}

/* Responsive foundation */
@media (max-width: 767px) {
    .px-8 {
        padding-left: clamp(1rem, 5vw, 1.5rem) !important;
        padding-right: clamp(1rem, 5vw, 1.5rem) !important;
    }

    .p-8,
    .p-10,
    .p-12,
    .p-16,
    .p-20,
    .p-24 {
        padding: 1.5rem !important;
    }

    .py-20,
    .py-24,
    .py-32,
    .py-40 {
        padding-top: 5rem !important;
        padding-bottom: 5rem !important;
    }

    .gap-12,
    .gap-16,
    .gap-20,
    .gap-24 {
        gap: 3rem !important;
    }

    .mb-20,
    .mb-24,
    .mb-32 {
        margin-bottom: 4rem !important;
    }

    .mt-20,
    .mt-24 {
        margin-top: 4rem !important;
    }

    .rounded-3xl,
    .rounded-\[2rem\],
    .rounded-\[3rem\],
    .rounded-\[40px\] {
        border-radius: 1.5rem !important;
    }

    .text-7xl,
    .text-6xl {
        font-size: clamp(2.5rem, 12vw, 4rem) !important;
        line-height: 1.08 !important;
    }

    .text-5xl {
        font-size: clamp(2.25rem, 10vw, 3.25rem) !important;
        line-height: 1.12 !important;
    }

    .text-4xl {
        font-size: clamp(2rem, 8vw, 2.25rem) !important;
        line-height: 1.18 !important;
    }

    .text-3xl {
        font-size: clamp(1.65rem, 7vw, 1.875rem) !important;
        line-height: 1.22 !important;
    }

    .text-2xl {
        font-size: 1.35rem !important;
        line-height: 1.35 !important;
    }

    .text-xl {
        font-size: 1.125rem !important;
        line-height: 1.65 !important;
    }

    .text-\[20rem\] {
        font-size: 10rem !important;
    }

    .quality-animation {
        min-height: 13rem;
    }

    .quality-animation__content {
        min-height: 13rem;
    }

    .domain-language-banner {
        right: 1rem;
        bottom: 1rem;
        width: calc(100vw - 2rem);
    }

    .domain-language-banner__inner {
        align-items: stretch;
        flex-direction: column;
    }

    .domain-language-banner__actions {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .px-8 {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }

    .p-8,
    .p-10,
    .p-12,
    .p-16,
    .p-20,
    .p-24 {
        padding: 1.25rem !important;
    }

    .py-20,
    .py-24,
    .py-32,
    .py-40 {
        padding-top: 4rem !important;
        padding-bottom: 4rem !important;
    }

    .gap-8,
    .gap-10,
    .gap-12,
    .gap-16,
    .gap-20,
    .gap-24 {
        gap: 2rem !important;
    }

    .text-7xl,
    .text-6xl {
        font-size: clamp(2.25rem, 12vw, 3rem) !important;
    }
}
