/*

Copyright 2026 MM Innovative Technologies

This is the official Style-Sheet for the MM Innovative Technologies Homepage
*/


:root {
    --primary: #0466c8;
    --primary-light: #3184d7;
    --text: #5c5d63;
    --heading: #000000;

    /* Surface tokens — overridden in dark mode below */
    --bg: #ffffff;
    --bg-soft: #f9f9f9;
    --bg-softer: #f1f1f1;
    --bg-card: #f3f4f5;
    --bg-input: #ffffff;
    --border: #d6d8da;
    --border-soft: #ececec;
}

@media (prefers-color-scheme: dark) {
    :root {
        --primary: #3a90df;
        --primary-light: #5fa6e7;
        --text: #a8aab0;
        --heading: #f4f4f6;

        --bg: #0b0b0d;
        --bg-soft: #131316;
        --bg-softer: #17171b;
        --bg-card: #1d1d22;
        --bg-input: #15151a;
        --border: #2a2a30;
        --border-soft: #1f1f25;
    }
}


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

body {
    font-family: "BeVietnamPro-Variable", Arial;
    background-color: var(--bg);
}

.container {
    max-width: 1800px;
    margin: 0 auto;
    /* overflow-x: clip lets us hide accidental horizontal overflow without
       breaking position: sticky on the header. */
    overflow-x: clip;
}

.header {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    padding: 14px 40px;
    margin: 0 0 40px 0;
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid var(--border-soft);
}

@media (prefers-color-scheme: dark) {
    .header {
        background: rgba(11, 11, 13, 0.72);
    }
}

.header ul {
    display: flex;
    gap: 4px;
    list-style: none;
    font-size: 15px;
}

.header ul a {
    color: var(--text);
    text-decoration: none;
    padding: 8px 14px;
    border-radius: 6px;
    transition: color 0.18s ease, background 0.18s ease;
    display: inline-flex;
    align-items: center;
    font-weight: 500;
}

.header ul a:hover {
    color: var(--heading);
    background: var(--bg-card);
}

.header ul a.is-active {
    color: var(--heading);
}

.header ul li.has-mega {
    position: static;
}

.header ul li.has-mega > a::after {
    content: '';
    display: inline-block;
    width: 0;
    height: 0;
    margin-left: 6px;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 4px solid currentColor;
    opacity: 0.5;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.header ul li.has-mega.is-open > a::after {
    transform: rotate(-180deg);
    opacity: 1;
}

/* Auth group: Register link + myMM CTA button */
.nav-auth {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.nav-register {
    color: var(--text);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    padding: 8px 6px;
    transition: color 0.18s ease;
    white-space: nowrap;
}

.nav-register:hover,
.nav-register:focus-visible {
    color: var(--heading);
    outline: none;
}

/* CTA button (myMM / Dashboard) */
.nav-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 18px;
    border-radius: 999px;
    background: var(--heading);
    color: var(--bg);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: transform 0.18s ease, background 0.18s ease;
    white-space: nowrap;
}

.nav-cta:hover,
.nav-cta:focus-visible {
    background: var(--primary);
    color: #ffffff;
    transform: translateY(-1px);
    outline: none;
}

.nav-cta-arrow {
    transition: transform 0.18s ease;
}

.nav-cta:hover .nav-cta-arrow {
    transform: translateX(2px);
}

.mega-panel {
    position: absolute;
    top: calc(100% + 8px);
    left: 40px;
    right: 40px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 28px 36px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
    z-index: 100;
    text-transform: none;
}

.header ul li.has-mega.is-open > .mega-panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.mega-see-all {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 20px;
    padding: 6px 0;
    color: var(--primary);
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    transition: gap 0.18s ease;
}

.mega-see-all:hover {
    gap: 10px;
    color: var(--primary);
}

/* Apps mega — .mega-grid holds the cards; .mega-apps wraps grid + see-all link */
.mega-apps .mega-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px 18px;
}

.mega-app-item {
    position: relative;
    flex: 0 1 calc((100% - 4 * 18px) / 5);
    min-width: 240px;
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 18px;
    border-radius: 6px;
    border: 1px solid var(--border-soft);
    background: var(--bg);
    text-decoration: none;
    color: inherit;
}

.mega-app-item:hover,
.mega-app-item:focus-visible {
    color: inherit;
    outline: none;
}

.mega-app-item .app-icon {
    position: relative;
    width: 40px;
    height: 40px;
    max-width: 40px;
    aspect-ratio: 1 / 1;
    border-radius: 10px;
    font-size: 1.2rem;
    flex: 0 0 auto;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.mega-app-text {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.mega-app-name {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 500;
    font-size: 1rem;
    color: var(--heading);
    line-height: 1.2;
}

.mega-app-desc {
    font-size: 0.82rem;
    color: var(--text);
    line-height: 1.35;
}

/* Services mega — .mega-grid holds the cards; .mega-services wraps grid + see-all link */
.mega-services .mega-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}

.mega-service-item {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 22px;
    border-radius: 6px;
    border: 1px solid var(--border-soft);
    background: var(--bg);
    text-decoration: none;
    color: inherit;
}

.mega-service-item:hover,
.mega-service-item:focus-visible {
    color: inherit;
    outline: none;
}

.mega-service-title {
    position: relative;
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 500;
    font-size: 1.15rem;
    color: var(--heading);
    line-height: 1.2;
}

.mega-service-desc {
    position: relative;
    font-size: 0.9rem;
    color: var(--text);
    line-height: 1.45;
}

/* Animated border that traces from top-center clockwise on hover.
   Uses a conic-gradient masked to a ring around the card. */
@property --border-progress {
    syntax: '<number>';
    inherits: true;
    initial-value: 0;
}

.mega-app-item,
.mega-service-item {
    --stroke-color: #2a2b2f;
    transition: --border-progress 0.55s ease;
}

@media (prefers-color-scheme: dark) {
    .mega-app-item,
    .mega-service-item {
        --stroke-color: #d4d4d8;
    }
}

.mega-app-item::before,
.mega-service-item::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: conic-gradient(
        from -90deg,
        var(--stroke-color) 0deg,
        var(--stroke-color) calc(var(--border-progress) * 1deg),
        transparent calc(var(--border-progress) * 1deg)
    );
    -webkit-mask:
        linear-gradient(#000 0 0) content-box,
        linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
            mask:
        linear-gradient(#000 0 0) content-box,
        linear-gradient(#000 0 0);
            mask-composite: exclude;
    pointer-events: none;
}

.mega-app-item:hover,
.mega-app-item:focus-visible,
.mega-service-item:hover,
.mega-service-item:focus-visible {
    --border-progress: 360;
}

/* Narrow viewports: hide mega panels and wrap the nav onto a second row
   below the logo + CTA. The nav row scrolls horizontally if it overflows. */
@media (max-width: 900px) {
    .header {
        flex-wrap: wrap;
        row-gap: 8px;
    }

    .header .name {
        flex: 1 1 auto;
    }

    .header nav {
        order: 99;
        flex-basis: 100%;
        overflow-x: auto;
        scrollbar-width: none;
        -ms-overflow-style: none;
        margin: 0 -16px;
        padding: 0 16px;
    }

    .header nav::-webkit-scrollbar {
        display: none;
    }

    .header ul {
        flex-wrap: nowrap;
    }

    .header ul a {
        white-space: nowrap;
    }

    .header ul li.has-mega > a::after { display: none; }
    .mega-panel { display: none; }
}

.header .name {
    font-family: "ClashDisplay-Bold", Arial;
    text-decoration: none;
    color: inherit;
    display: inline-flex;
    align-items: baseline;
    gap: 8px;
    line-height: 1;
    transition: opacity 0.18s ease;
}

.header .name:hover,
.header .name:focus-visible {
    text-decoration: none;
    opacity: 0.75;
    outline: none;
}

.header .name .brand-mark {
    font-size: 1.6rem;
    color: var(--heading);
    line-height: 1;
}

.header .name .brand-sub {
    font-size: 1.15rem;
    color: var(--primary);
    font-weight: 500;
}

/* Compact variant on myMM pages — slightly tighter still. */
.header.header-compact {
    margin-bottom: 24px;
}

.header.header-compact .name .brand-mark {
    font-size: 1.4rem;
}

.header.header-compact .name .brand-sub {
    font-size: 1rem;
}

.brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 60px 40px 20px 40px;
}

.brand .brand-icon {
    width: 100px;
    height: 50px;
    flex-shrink: 0;
    background-image: url("/includes/img/LogoDarkBG.png");
    background-repeat: no-repeat;
    background-position: center bottom;
    background-size: 100% 200%;
}

.brand h1 {
    font: inherit;
    margin: 0;
    line-height: inherit;
    letter-spacing: inherit;
    color: inherit;
}

.brand .bold {
    font-weight: 600;
}
.brand .light {
    font-weight: 200;
}

.aboutus {
    padding: 100px 40px;
    background-color: #f1f1f1;
}

h2 {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 500;
}

.aboutus .divider {
    border-bottom: 1px solid #d6d8da;
    margin: 60px 0;
}

.lr {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
}
.lr .r p {
    color: var(--text);
    margin-bottom: 15px;
}


.products {
    padding: 120px 40px;
    background-color: #f9f9f9;
}

.products-top {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 60px;
    align-items: start;
    margin-bottom: 100px;
}

.products-top h2 {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 600;
    font-size: 3rem;
    line-height: 1.05;
    color: var(--heading);
}

.products-top p {
    color: var(--text);
    line-height: 1.5;
    padding-top: 10px;
}

.products-top .btn-cta {
    justify-self: end;
    align-self: start;
}

.apps-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
}

.app-item {
    flex: 0 1 calc((100% - 4 * 30px) / 5);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 14px;
    text-decoration: none;
    color: inherit;
    transition: transform 0.25s ease;
}

.app-item:hover {
    transform: translateY(-4px);
}

.app-icon {
    width: 100%;
    aspect-ratio: 1 / 1;
    max-width: 110px;
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 2.8rem;
    line-height: 1;
    color: #ffffff;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.app-name {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 400;
    font-size: 1.1rem;
    color: var(--heading);
    margin-top: 4px;
}

.app-tag {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text);
}

.a-parcel   { background-color: #4f46e5; }
.a-ember    { background-color: #e8743b; }
.a-delta    { background-color: #0969da; }
.a-tarex    { background-color: #1a1a1a; }
.a-ledger   { background-color: #1f7a55; }
.a-mask     { background-color: #444444; }
.a-frameit  { background-color: #8c1f4c; }

/* When an image is set via apps-data.php `icon_image`, the image fills the
   tile and replaces the letter. The background-color is irrelevant. */
.app-icon--image {
    padding: 0;
    overflow: hidden;
    background-color: transparent !important;
}

.app-icon--image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    border-radius: inherit;
}

.apps-hero {
    padding: 80px 40px 40px 40px;
}

.apps-hero h1 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 4.5rem;
    line-height: 1;
    color: var(--heading);
    margin-bottom: 20px;
}

.apps-hero p {
    color: var(--text);
    line-height: 1.55;
    max-width: 520px;
    font-size: 1.05rem;
}

.app-features {
    padding: 40px 40px 120px 40px;
}

.app-feature-row {
    display: flex;
    align-items: center;
    gap: 100px;
    padding: 80px 0;
}

.app-feature-row + .app-feature-row {
    border-top: 1px solid #ececec;
}

.app-feature-row:nth-child(even) {
    flex-direction: row-reverse;
}

.app-feature-icon {
    flex: 0 0 auto;
    display: flex;
    justify-content: center;
    width: 280px;
}

.app-feature-icon .app-icon {
    width: 240px;
    height: 240px;
    max-width: 240px;
    border-radius: 44px;
    font-size: 7rem;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.1);
}

.app-feature-content {
    flex: 1;
    max-width: 560px;
}

.app-feature-content .app-tag {
    display: block;
    color: var(--text);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 14px;
}

.app-feature-content h2 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 3rem;
    line-height: 1.05;
    color: var(--heading);
    margin-bottom: 18px;
}

.app-feature-content p {
    color: var(--text);
    line-height: 1.6;
    margin-bottom: 26px;
}


/* ===== App detail page ===== */

.app-detail-hero {
    padding: 100px 40px 60px 40px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.app-icon-hero {
    width: 140px !important;
    height: 140px !important;
    max-width: 140px !important;
    border-radius: 32px;
    font-size: 4.5rem !important;
    margin-bottom: 30px;
}

.app-detail-hero .app-tag {
    color: var(--text);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 12px;
}

.app-detail-hero h1 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 5rem;
    line-height: 1;
    color: var(--heading);
    margin-bottom: 18px;
}

.app-detail-pricing {
    font-size: 0.95rem;
    color: var(--text);
    margin-bottom: 20px;
}

.app-detail-pricing strong {
    color: var(--heading);
    font-weight: 600;
}

.app-detail-tagline {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 400;
    font-size: 1.5rem;
    color: var(--heading);
    margin-bottom: 24px;
    max-width: 640px;
}

.app-detail-intro {
    color: var(--text);
    line-height: 1.6;
    max-width: 580px;
    margin-bottom: 32px;
}

.app-detail-screenshot {
    padding: 20px 40px 60px 40px;
}

.screenshot-placeholder {
    width: 100%;
    aspect-ratio: 16 / 9;
    background-color: #f3f4f5;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text);
    font-size: 0.85rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    border: 1px dashed #d6d8da;
}

.screenshot-placeholder.small {
    aspect-ratio: 4 / 3;
    border-radius: 12px;
}

/* real screenshots — drop into the same footprint as the placeholders */
.app-screenshot {
    width: 100%;
    height: auto;
    border-radius: 16px;
    border: 1px solid var(--border);
    display: block;
}

.app-screenshot.small {
    border-radius: 12px;
}

/* tinted screenshot placeholders */
.screenshot-placeholder.a-parcel-tint { background-color: rgba(79, 70, 229, 0.08); }
.screenshot-placeholder.a-ember-tint  { background-color: rgba(232, 116, 59, 0.08); }
.screenshot-placeholder.a-delta-tint  { background-color: rgba(9, 105, 218, 0.08); }
.screenshot-placeholder.a-tarex-tint  { background-color: rgba(26, 26, 26, 0.05); }
.screenshot-placeholder.a-ledger-tint { background-color: rgba(31, 122, 85, 0.08); }
.screenshot-placeholder.a-mask-tint   { background-color: rgba(68, 68, 68, 0.06); }

.app-detail-features {
    padding: 60px 40px;
}

.feature-cols {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 50px;
}

.feature-item h3 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 1.3rem;
    margin-bottom: 12px;
    color: var(--heading);
}

.feature-item p {
    color: var(--text);
    line-height: 1.6;
}

.app-detail-sections {
    padding: 60px 40px;
}

.app-detail-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
    padding: 60px 0;
}

.app-detail-row:nth-child(even) .app-detail-visual {
    order: 2;
}

.app-detail-text h3 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 2rem;
    line-height: 1.1;
    color: var(--heading);
    margin-bottom: 16px;
}

.app-detail-text p {
    color: var(--text);
    line-height: 1.65;
    max-width: 480px;
}

.app-detail-cta {
    padding: 100px 40px 120px 40px;
    text-align: center;
    background-color: #f9f9f9;
}

.app-detail-cta h2 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 2.5rem;
    color: var(--heading);
    margin-bottom: 30px;
}

.app-detail-cta-actions {
    display: inline-flex;
    align-items: center;
    gap: 24px;
}

.link-quiet {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.link-quiet:hover {
    color: var(--primary);
}


/* ===== Legal pages (terms, privacy) ===== */

.legal-page {
    padding: 60px 40px 120px 40px;
    max-width: 760px;
    margin: 0 auto;
}

.legal-hero {
    margin-bottom: 32px;
}

.legal-hero h1 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 3rem;
    line-height: 1.05;
    color: var(--heading);
    margin-bottom: 10px;
}

.legal-meta {
    color: var(--text);
    font-size: 0.9rem;
}

.legal-notice {
    background: rgba(232, 116, 59, 0.08);
    border: 1px solid rgba(232, 116, 59, 0.3);
    color: var(--heading);
    padding: 16px 22px;
    border-radius: 12px;
    margin-bottom: 40px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.legal-body h2 {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 600;
    font-size: 1.25rem;
    color: var(--heading);
    margin-top: 36px;
    margin-bottom: 12px;
}

.legal-body h2:first-of-type {
    margin-top: 0;
}

.legal-body p {
    color: var(--text);
    line-height: 1.7;
    margin-bottom: 14px;
}

.legal-body ul {
    color: var(--text);
    line-height: 1.7;
    margin-bottom: 14px;
    padding-left: 22px;
}

.legal-body li {
    margin-bottom: 6px;
}

.legal-body a {
    color: var(--primary);
    text-decoration: none;
}

.legal-body a:hover {
    text-decoration: underline;
}

@media (max-width: 600px) {
    .legal-page {
        padding: 40px 20px 80px 20px;
    }
    .legal-hero h1 {
        font-size: 2.25rem;
    }
}


/* ===== /download/<slug> ===== */

.download-page {
    padding: 60px 40px 120px 40px;
    max-width: 760px;
    margin: 0 auto;
}

.download-hero {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 60px;
}

.download-hero .app-icon {
    width: 96px !important;
    height: 96px !important;
    max-width: 96px !important;
    font-size: 2.6rem !important;
    border-radius: 22px !important;
    margin-bottom: 20px;
}

.download-hero h1 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 2.6rem;
    line-height: 1.05;
    color: var(--heading);
    margin-bottom: 10px;
}

.download-tagline {
    color: var(--text);
    font-size: 1.05rem;
    line-height: 1.5;
}

.download-block {
    margin-bottom: 40px;
}

.download-block h2 {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 500;
    font-size: 1.1rem;
    color: var(--text);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 16px;
}

.download-block.is-primary h2 {
    color: var(--heading);
}

.download-variants {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
}

.download-btn {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 22px 24px;
    background: var(--bg-soft);
    border: 1px solid var(--border-soft);
    border-radius: 14px;
    color: var(--heading);
    text-decoration: none;
    transition: transform 0.15s, border-color 0.15s, background-color 0.15s;
}

.download-btn:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
}

.download-block.is-primary .download-btn {
    background: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
}

.download-block.is-primary .download-btn:hover {
    background: var(--primary-light);
    border-color: var(--primary-light);
    transform: translateY(-2px);
}

.download-btn-title {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 1.1rem;
    line-height: 1;
}

.download-btn-sub {
    font-size: 0.8rem;
    opacity: 0.75;
}

.download-btn-size {
    font-size: 0.75rem;
    opacity: 0.55;
    margin-top: 6px;
}

.download-btn.is-disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.download-footnote {
    margin-top: 30px;
    color: var(--text);
    font-size: 0.85rem;
    text-align: center;
}

.download-footnote a {
    color: var(--primary);
    text-decoration: none;
}

@media (max-width: 600px) {
    .download-page {
        padding: 40px 20px 80px 20px;
    }
    .download-hero h1 {
        font-size: 2rem;
    }
    .download-variants {
        grid-template-columns: 1fr;
    }
}


/* ===== myMM auth pages ===== */

.auth-page {
    min-height: 60vh;
    padding: 80px 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-card {
    width: 100%;
    max-width: 460px;
    background: #f9f9f9;
    padding: 50px;
    border-radius: 18px;
}

.auth-card h1 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 2rem;
    color: var(--heading);
    margin-bottom: 12px;
    line-height: 1.1;
}

.auth-sub {
    color: var(--text);
    margin-bottom: 30px;
    line-height: 1.5;
}

.auth-form .field {
    margin-bottom: 22px;
}

.auth-submit {
    width: 100%;
    text-align: center;
    margin-top: 16px;
    border: none;
    cursor: pointer;
    font-family: inherit;
}

.auth-alt {
    color: var(--text);
    margin-top: 24px;
    font-size: 0.95rem;
}

.auth-alt a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}

.auth-alt a:hover {
    text-decoration: underline;
}

.form-error {
    background: rgba(220, 53, 69, 0.08);
    color: #b3261e;
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.form-success {
    background: rgba(43, 157, 110, 0.1);
    color: #1f7a55;
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 30px;
    font-size: 0.9rem;
}

.form-info {
    background: rgba(4, 102, 200, 0.08);
    color: var(--primary);
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 30px;
    font-size: 0.9rem;
}

.btn-danger {
    background-color: #b3261e;
    color: #ffffff;
    border: none;
    padding: 14px 22px;
    cursor: pointer;
    font-family: inherit;
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    transition: background-color 0.2s;
}

.btn-danger:hover {
    background-color: #8a1d17;
}

.danger-link {
    color: #b3261e !important;
}

.danger-link:hover {
    color: #8a1d17 !important;
}

.badge {
    display: inline-block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 3px 10px;
    border-radius: 999px;
    margin-left: 6px;
    font-weight: 600;
}

.badge.verified {
    background: rgba(43, 157, 110, 0.12);
    color: #1f7a55;
}

.badge.unverified {
    background: rgba(232, 116, 59, 0.14);
    color: #c25817;
}

.badge.coming-soon {
    background: rgba(4, 102, 200, 0.1);
    color: var(--primary);
}

/* Verify email banner */
.verify-banner {
    background: rgba(232, 116, 59, 0.08);
    border: 1px solid rgba(232, 116, 59, 0.3);
    color: var(--heading);
    padding: 16px 22px;
    border-radius: 12px;
    margin-bottom: 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.verify-banner strong {
    display: block;
    color: var(--heading);
    margin-bottom: 4px;
}

.verify-banner span {
    color: var(--text);
    font-size: 0.9rem;
}

.verify-banner form button {
    background: transparent;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 0.9rem;
    padding: 0;
    color: var(--primary);
    font-weight: 600;
}

.dashboard-actions {
    display: flex;
    gap: 20px;
    align-items: center;
}

.dash-app-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.dash-app-actions form {
    margin: 0;
}

.dash-app-actions form button {
    background: transparent;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 0.9rem;
    padding: 0;
}

/* Account page */
.account-sections {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.account-section {
    background: #f9f9f9;
    border-radius: 16px;
    padding: 30px;
    max-width: 560px;
    width: 100%;
}

.account-section h2 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 1.4rem;
    color: var(--heading);
    margin-bottom: 18px;
}

.account-section--danger {
    background: rgba(179, 38, 30, 0.04);
    border: 1px solid rgba(179, 38, 30, 0.15);
}

.account-section--danger h2 {
    color: #b3261e;
}

.account-section--wide {
    max-width: 720px;
}

/* Devices page */
.devices-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.token-reveal {
    width: 100%;
    max-width: 720px;
    margin: 0 auto 40px;
    padding: 30px;
    border-radius: 16px;
    background: rgba(43, 157, 110, 0.08);
    border: 1px solid rgba(43, 157, 110, 0.3);
}

.token-reveal h2 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 1.3rem;
    color: var(--heading);
    margin-bottom: 12px;
}

.token-reveal p {
    color: var(--text);
    line-height: 1.5;
    margin-bottom: 16px;
}

.token-value {
    display: block;
    background: var(--bg);
    border: 1px solid var(--border);
    padding: 16px 18px;
    border-radius: 10px;
    font-family: "JetBrains Mono", "Menlo", "Consolas", monospace;
    font-size: 0.85rem;
    word-break: break-all;
    margin-bottom: 14px;
    user-select: all;
    color: var(--heading);
}

.device-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.device-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 16px;
    background: var(--bg);
    border-radius: 10px;
    border: 1px solid var(--border-soft);
}

.device-row strong {
    display: block;
    color: var(--heading);
    margin-bottom: 4px;
}

.device-row span {
    color: var(--text);
    font-size: 0.85rem;
}

.device-row form {
    margin: 0;
}

.device-row form button {
    background: transparent;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 0.85rem;
    padding: 0;
}

/* /mymm/connect approval card */
.connect-card {
    max-width: 520px;
}

.connect-app {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 24px;
}

.connect-app .app-icon {
    width: 64px !important;
    height: 64px !important;
    max-width: 64px !important;
    aspect-ratio: 1 / 1;
    flex-shrink: 0;
    font-size: 1.8rem !important;
    border-radius: 14px !important;
    box-shadow: none !important;
    margin: 0 !important;
}

.connect-app h1 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 1.6rem;
    color: var(--heading);
    margin: 0 0 4px 0;
    line-height: 1.1;
}

.connect-app .auth-sub {
    margin-bottom: 0;
}

.connect-scope {
    list-style: none;
    padding: 18px 22px;
    margin: 0 0 24px 0;
    background: var(--bg);
    border: 1px solid var(--border-soft);
    border-radius: 12px;
    color: var(--text);
    font-size: 0.95rem;
    line-height: 1.7;
}

.connect-scope li::before {
    content: "✓";
    color: #1f7a55;
    margin-right: 10px;
    font-weight: 700;
}

.connect-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 16px;
}

.connect-actions .btn-cta {
    flex: 1;
    text-align: center;
    border: none;
    font-family: inherit;
    cursor: pointer;
}

.connect-actions .link-quiet {
    background: transparent;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 1rem;
    padding: 0;
}

.field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    margin-bottom: 22px;
}

.field-row .field {
    margin-bottom: 0;
}

.field-narrow {
    max-width: 180px;
}

.field .required {
    color: #b3261e;
    font-weight: 600;
}

@media (max-width: 600px) {
    .field-row {
        grid-template-columns: 1fr;
    }

    .field-narrow {
        max-width: none;
    }
}

.account-note {
    color: var(--text);
    margin-bottom: 18px;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Pricing — current plan + per-plan CTA */
.pricing-plan.current {
    outline: 2px solid #1f7a55;
}

.plan-cta {
    width: 100%;
    text-align: center;
    margin-top: 16px;
    border: none;
    cursor: pointer;
    font-family: inherit;
}

.plan-cta-form {
    margin: 0;
}

.plan-cta-quiet {
    display: inline-block;
    margin-top: 16px;
    font-size: 0.85rem;
    color: #1f7a55;
}


/* ===== myMM dashboard ===== */

.dashboard {
    padding: 80px 40px 120px 40px;
}

.dashboard-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 30px;
    margin-bottom: 60px;
}

.dashboard-header h1 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 3rem;
    color: var(--heading);
    line-height: 1;
    margin-bottom: 8px;
}

.dashboard-header p {
    color: var(--text);
}

.logout-form button {
    background: transparent;
    border: none;
    font-family: inherit;
    font-size: 0.95rem;
    cursor: pointer;
    padding: 0;
}

.dashboard-section-title {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 500;
    font-size: 1.5rem;
    color: var(--heading);
    margin-bottom: 24px;
}

.dashboard-apps {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.dash-app-card {
    background: #f9f9f9;
    border-radius: 16px;
    padding: 26px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.dash-app-head {
    display: flex;
    align-items: center;
    gap: 14px;
}

.dash-app-head .app-icon {
    width: 56px !important;
    height: 56px !important;
    max-width: 56px !important;
    font-size: 1.5rem !important;
    border-radius: 14px !important;
    box-shadow: none !important;
}

.dash-app-head h3 {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--heading);
    margin-bottom: 4px;
}

.dash-app-head .app-tag {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text);
}

.dash-app-status {
    display: flex;
    flex-direction: column;
    padding: 14px 16px;
    border-radius: 10px;
    gap: 3px;
}

.dash-app-status.active {
    background: rgba(43, 157, 110, 0.08);
    color: #1f7a55;
}

.dash-app-status.inactive {
    background: rgba(0, 0, 0, 0.04);
    color: var(--text);
}

.dash-app-status.cancelled {
    background: rgba(232, 116, 59, 0.1);
    color: #c25817;
}

.dash-app-status.pending {
    background: rgba(4, 102, 200, 0.08);
    color: var(--primary);
}

.dash-app-status strong {
    font-weight: 600;
}

.dash-app-status span {
    font-size: 0.85rem;
}

.dash-app-card .btn-cta,
.dash-app-card .link-quiet {
    align-self: flex-start;
}

.dashboard-note {
    margin-top: 50px;
    color: var(--text);
    font-size: 0.9rem;
}

.dashboard-note a {
    color: var(--primary);
}


/* ===== Pricing page ===== */

.pricing-list {
    padding: 40px 40px 120px 40px;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.pricing-card {
    background: #f9f9f9;
    border-radius: 18px;
    padding: 40px;
    display: grid;
    grid-template-columns: 1fr 2.4fr auto;
    gap: 40px;
    align-items: center;
}

.pricing-card-head {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.pricing-card-head .app-icon {
    width: 70px !important;
    height: 70px !important;
    max-width: 70px !important;
    font-size: 2rem !important;
    border-radius: 18px !important;
}

.pricing-card-head h2 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 1.8rem;
    color: var(--heading);
}

.pricing-card-head .app-tag {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text);
}

.pricing-plans {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}

.pricing-plan {
    background: #ffffff;
    border-radius: 12px;
    padding: 22px;
}

.pricing-plan.featured {
    outline: 2px solid var(--primary);
}

.plan-name {
    display: block;
    font-weight: 600;
    color: var(--heading);
    margin-bottom: 6px;
}

.plan-price {
    display: block;
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 1.6rem;
    color: var(--heading);
    margin-bottom: 16px;
    line-height: 1;
}

.plan-price span {
    font-family: "BeVietnamPro-Variable", Arial;
    font-weight: 400;
    font-size: 0.85rem;
    color: var(--text);
}

.plan-features {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.9rem;
    color: var(--text);
    line-height: 1.5;
}

.plan-features li {
    padding: 4px 0;
}

.pricing-card-cta {
    display: flex;
    align-items: center;
}

.pricing-note {
    margin-top: 30px;
    color: var(--text);
    font-size: 0.9rem;
}

.pricing-note a {
    color: var(--primary);
}

.pricing-card-note {
    grid-column: 1 / -1;
    margin-top: 6px;
    color: var(--text);
    font-size: 0.9rem;
    background: rgba(4, 102, 200, 0.06);
    padding: 12px 16px;
    border-radius: 8px;
}

.testimonials {
    padding: 120px 40px;
}

.testimonials-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 70px;
}

.testimonials-top h2 {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 600;
    font-size: 3rem;
    line-height: 1.05;
    color: var(--heading);
}

.testimonials-nav {
    display: flex;
    gap: 12px;
}

.nav-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid #d6d8da;
    background: transparent;
    color: var(--heading);
    cursor: pointer;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s, color 0.2s;
}

.nav-btn:hover {
    background-color: var(--heading);
    color: #ffffff;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 24px;
    margin-bottom: 40px;
}

.testimonial-card {
    background-color: #f3f4f5;
    border-radius: 14px;
    padding: 30px 30px 40px 30px;
    display: flex;
    flex-direction: column;
    gap: 30px;
    min-height: 360px;
}

.testimonial-num {
    color: var(--text);
    font-size: 0.95rem;
    font-weight: 500;
}

.testimonial-body {
    flex: 1;
    color: var(--heading);
    line-height: 1.55;
}

.testimonial-body p {
    margin-bottom: 12px;
}

.testimonial-body p:last-child {
    margin-bottom: 0;
}

.testimonial-author {
    color: var(--text);
    font-size: 0.9rem;
    line-height: 1.55;
}

.logo-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 20px;
}

.logo-cell {
    background-color: #f3f4f5;
    border-radius: 14px;
    aspect-ratio: 5 / 3;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--heading);
    font-weight: 600;
    font-size: 1.05rem;
    letter-spacing: 0.01em;
}

.faq {
    padding: 120px 40px;
}

.faq-top {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 60px;
    align-items: start;
    margin-bottom: 100px;
}

.faq-top h1,
.faq-top h2 {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 600;
    font-size: 3rem;
    line-height: 1.05;
    color: var(--heading);
    margin: 0;
}

.faq-top p {
    color: var(--text);
    line-height: 1.5;
    padding-top: 10px;
}

.btn-cta {
    justify-self: end;
    align-self: start;
    display: inline-block;
    background-color: var(--primary);
    color: #ffffff;
    text-decoration: none;
    text-transform: uppercase;
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.04em;
    padding: 14px 22px;
    transition: background-color 0.2s;
}

.btn-cta:hover {
    background-color: var(--primary-light);
}

.faq-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    column-gap: 60px;
    row-gap: 70px;
}

.faq-item {
    grid-column: span 1;
}

.faq-item:nth-child(odd) {
    grid-column-start: 2;
}

.faq-item h3 {
    font-weight: 600;
    font-size: 1.05rem;
    margin-bottom: 12px;
    color: var(--heading);
}

.faq-item p {
    color: var(--text);
    line-height: 1.55;
}

.faq-item p a {
    color: var(--primary);
    text-decoration: none;
}

.faq-item p a:hover {
    text-decoration: underline;
}

/* Dedicated FAQ page */
.faq-list {
    padding: 40px 40px 120px 40px;
    display: flex;
    flex-direction: column;
    gap: 70px;
}

.faq-group-title {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 500;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text);
    margin-bottom: 24px;
}

.faq-list .faq-items {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 60px;
    row-gap: 40px;
}

.faq-cta {
    margin-top: 20px;
    padding: 50px 40px;
    background-color: #f9f9f9;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

.faq-cta h2 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 1.6rem;
    color: var(--heading);
}

@media (max-width: 1024px) {
    .faq-list {
        padding: 30px 20px 80px 20px;
        gap: 50px;
    }
    .faq-list .faq-items {
        grid-template-columns: 1fr;
        row-gap: 28px;
    }
    .faq-cta {
        flex-direction: column;
        text-align: center;
        padding: 35px 25px;
    }
}

.contact {
    padding: 120px 40px;
    background-color: #f9f9f9;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: start;
}

.contact-intro h1,
.contact-intro h2 {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 600;
    font-size: 3rem;
    line-height: 1.05;
    color: var(--heading);
    margin: 0 0 24px;
}

.contact-intro p {
    color: var(--text);
    line-height: 1.6;
    margin-bottom: 30px;
    max-width: 480px;
}

.contact-info a {
    color: var(--heading);
    text-decoration: none;
    font-weight: 600;
    border-bottom: 1px solid var(--heading);
    padding-bottom: 2px;
    transition: color 0.2s, border-color 0.2s;
}

.contact-info a:hover {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

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

.field {
    display: flex;
    flex-direction: column;
    margin-bottom: 26px;
}

.field label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text);
    margin-bottom: 8px;
}

.field input,
.field textarea {
    background: transparent;
    border: none;
    border-bottom: 1px solid #d6d8da;
    outline: none;
    padding: 10px 0;
    font: inherit;
    color: var(--heading);
    transition: border-color 0.2s;
}

.field textarea {
    resize: vertical;
    min-height: 100px;
}

.field input:focus,
.field textarea:focus {
    border-bottom-color: var(--primary);
}

.contact-form .btn-cta {
    align-self: flex-start;
    margin-top: 14px;
    cursor: pointer;
    border: none;
    font-family: inherit;
}

.footer {
    background-color: #0e0e0e;
    color: #ffffff;
    overflow: hidden;
}

.footer-inner {
    max-width: 1800px;
    margin: 0 auto;
    padding: 100px 40px 0 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr auto auto auto;
    column-gap: 80px;
    row-gap: 60px;
    padding-bottom: 100px;
}

.footer h2 {
    font-family: "ClashDisplay-Variable", Arial;
    font-weight: 500;
    font-size: 2rem;
    color: #ffffff;
    margin-bottom: 30px;
}

.footer h3 {
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 20px;
    color: #ffffff;
}

.footer ul {
    list-style: none;
    margin-bottom: 30px;
}

.footer ul li {
    margin-bottom: 8px;
}

.footer a {
    color: #b3b3b3;
    text-decoration: none;
    transition: color 0.2s;
}

.footer a:hover {
    color: #ffffff;
}

.footer-contact {
    color: #b3b3b3;
    margin-bottom: 40px;
    line-height: 1.6;
}

.footer-newsletter-label {
    font-weight: 600;
    margin-bottom: 15px;
}

.footer-newsletter {
    display: flex;
    align-items: center;
    border-bottom: 1px solid #3a3a3a;
    max-width: 320px;
}

.footer-newsletter input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: #ffffff;
    padding: 10px 0;
    font: inherit;
}

.footer-newsletter input::placeholder {
    color: #6a6a6a;
}

.footer-newsletter button {
    background: transparent;
    border: none;
    color: #b3b3b3;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 10px;
    transition: color 0.2s;
}

.footer-newsletter button:hover {
    color: #ffffff;
}

.footer-meta {
    color: #b3b3b3;
    margin-top: 30px;
    line-height: 1.6;
}

.footer-wordmark {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: clamp(8rem, 28vw, 24rem);
    line-height: 0.85;
    color: #ffffff;
    margin-left: -0.05em;
    margin-bottom: -0.15em;
}

.footer-bottom {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
}

.footer-copyright {
    color: #6a6a6a;
    font-size: 0.75rem;
    padding-bottom: 30px;
    text-align: right;
    flex-shrink: 0;
}

@media (max-width: 1024px) {
    .header {
        padding: 12px 24px;
        gap: 16px;
    }

    .header .name .brand-sub {
        display: none;
    }

    .header ul {
        gap: 2px;
    }

    .header ul a {
        padding: 6px 10px;
        font-size: 14px;
    }

    .brand {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 20px;
        margin: 40px 20px 60px 20px;
    }

    .brand .brand-icon {
        width: 80px;
        height: 40px;
    }

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

    .lr .l {
        order: -1;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
        padding-bottom: 40px;
    }

    .footer-inner {
        padding: 40px 20px 0 20px;
    }

    .faq {
        padding: 60px 20px;
    }

    .faq-top {
        grid-template-columns: 1fr;
        gap: 25px;
        margin-bottom: 50px;
    }

    .faq-top h1,
    .faq-top h2 {
        font-size: 2.25rem;
    }

    .btn-cta {
        justify-self: start;
    }

    .faq-grid {
        grid-template-columns: 1fr 1fr;
        row-gap: 35px;
    }

    .faq-item:nth-child(odd) {
        grid-column-start: auto;
    }

    .products {
        padding: 60px 20px;
    }

    .products-top {
        grid-template-columns: 1fr;
        gap: 25px;
        margin-bottom: 40px;
    }

    .products-top h2 {
        font-size: 2.25rem;
    }

    .products-top .btn-cta {
        justify-self: start;
    }

    .apps-row {
        gap: 30px 20px;
    }

    .apps-row .app-item {
        flex: 0 1 calc((100% - 2 * 20px) / 3);
    }

    .apps-hero {
        padding: 60px 20px 30px 20px;
    }

    .apps-hero h1 {
        font-size: 3rem;
    }

    .app-features {
        padding: 30px 20px 80px 20px;
    }

    .app-feature-row,
    .app-feature-row:nth-child(even) {
        flex-direction: column;
        gap: 30px;
        padding: 50px 0;
        text-align: center;
        align-items: center;
    }

    .app-feature-icon {
        width: auto;
    }

    .app-feature-icon .app-icon {
        width: 160px;
        height: 160px;
        max-width: 160px;
        border-radius: 32px;
        font-size: 4.5rem;
    }

    .app-feature-content h2 {
        font-size: 2.25rem;
    }

    .app-feature-content {
        max-width: 100%;
    }

    .app-detail-hero {
        padding: 60px 20px 30px 20px;
    }

    .app-detail-hero h1 {
        font-size: 3.25rem;
    }

    .app-icon-hero {
        width: 110px !important;
        height: 110px !important;
        max-width: 110px !important;
        font-size: 3.5rem !important;
    }

    .app-detail-tagline {
        font-size: 1.2rem;
    }

    .app-detail-screenshot,
    .app-detail-features,
    .app-detail-sections {
        padding: 40px 20px;
    }

    .feature-cols {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .app-detail-row,
    .app-detail-row:nth-child(even) {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 40px 0;
    }

    .app-detail-row:nth-child(even) .app-detail-visual {
        order: 0;
    }

    .app-detail-cta {
        padding: 70px 20px 80px 20px;
    }

    .app-detail-cta h2 {
        font-size: 2rem;
    }

    .app-detail-cta-actions {
        flex-direction: column;
        gap: 18px;
    }

    .auth-page {
        padding: 50px 20px;
    }

    .auth-card {
        padding: 35px 25px;
    }

    .dashboard {
        padding: 50px 20px 80px 20px;
    }

    .dashboard-header {
        flex-direction: column;
        gap: 20px;
        margin-bottom: 40px;
    }

    .dashboard-header h1 {
        font-size: 2.25rem;
    }

    .pricing-list {
        padding: 30px 20px 80px 20px;
    }

    .pricing-card {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 30px;
    }

    .pricing-plans {
        grid-template-columns: 1fr;
    }

    .verify-banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .account-section {
        padding: 24px;
    }

    .testimonials {
        padding: 60px 20px;
    }

    .testimonials-top h2 {
        font-size: 2.25rem;
    }

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

    .testimonial-card {
        min-height: auto;
    }

    .logo-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .contact {
        padding: 60px 20px;
    }

    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .contact-intro h1,
    .contact-intro h2 {
        font-size: 2.25rem;
    }

    .footer-bottom {
        flex-direction: column-reverse;
        align-items: stretch;
        gap: 20px;
    }

    .footer-copyright {
        padding-bottom: 0;
    }
}

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

    .logo-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .header {
        padding: 10px 16px;
        gap: 8px;
    }

    .header .name .brand-mark {
        font-size: 1.4rem;
    }

    .header ul a {
        padding: 6px 8px;
        font-size: 13px;
    }

    .nav-cta {
        padding: 8px 14px;
        font-size: 13px;
    }

    .apps-row .app-item {
        flex: 0 1 calc((100% - 30px) / 2);
    }
}


/* ============================================================
   Dark mode (follows system theme via prefers-color-scheme)
   ============================================================ */

@media (prefers-color-scheme: dark) {
    body {
        background-color: var(--bg);
        color: var(--text);
    }

    /* Section backgrounds that were hardcoded */
    .aboutus              { background-color: var(--bg-softer); }
    .products,
    .contact,
    .app-detail-cta       { background-color: var(--bg-soft); }
    .abc                  { background-color: var(--bg-soft); }
    .def                  { background-color: var(--bg); }

    /* Cards & surfaces */
    .testimonial-card,
    .logo-cell,
    .dash-app-card,
    .auth-card,
    .account-section,
    .pricing-card,
    .pricing-plan {
        background-color: var(--bg-card);
    }
    .pricing-plan {
        background-color: var(--bg-softer);
    }

    .faq-cta {
        background-color: var(--bg-soft);
    }

    /* Logo cell text + testimonial text */
    .logo-cell             { color: var(--heading); }
    .testimonial-body      { color: var(--heading); }

    /* Borders */
    .aboutus .divider               { border-bottom-color: var(--border); }
    .field input,
    .field textarea                 { border-bottom-color: var(--border); color: var(--heading); }
    .field input::placeholder,
    .field textarea::placeholder    { color: var(--text); }
    .footer-newsletter              { border-bottom-color: var(--border); }
    .footer-newsletter input        { color: var(--heading); }
    .nav-btn                        { border-color: var(--border); color: var(--heading); }
    .nav-btn:hover                  { background-color: var(--heading); color: var(--bg); }
    .app-feature-row + .app-feature-row { border-top-color: var(--border-soft); }
    .screenshot-placeholder         { border-color: var(--border); background-color: var(--bg-softer); }

    /* Tinted screenshot placeholders — bump opacity so they're visible */
    .screenshot-placeholder.a-parcel-tint { background-color: rgba(79, 70, 229, 0.16); }
    .screenshot-placeholder.a-ember-tint  { background-color: rgba(232, 116, 59, 0.14); }
    .screenshot-placeholder.a-delta-tint  { background-color: rgba(9, 105, 218, 0.14); }
    .screenshot-placeholder.a-tarex-tint  { background-color: rgba(255, 255, 255, 0.06); }
    .screenshot-placeholder.a-ledger-tint { background-color: rgba(31, 122, 85, 0.18); }
    .screenshot-placeholder.a-mask-tint   { background-color: rgba(255, 255, 255, 0.05); }

    /* Status / info blocks */
    .dash-app-status.inactive       { background-color: var(--bg-softer); color: var(--text); }
    .dash-app-status.active         { background-color: rgba(43, 157, 110, 0.18); color: #7fd3ad; }
    .dash-app-status.cancelled      { background-color: rgba(232, 116, 59, 0.16); color: #f4a26b; }
    .dash-app-status.pending        { background-color: rgba(58, 144, 223, 0.18); color: #9cc6f0; }
    .pricing-card-note              { background-color: rgba(58, 144, 223, 0.1); color: var(--text); }
    .form-success                   { background-color: rgba(43, 157, 110, 0.18); color: #7fd3ad; }
    .form-info                      { background-color: rgba(58, 144, 223, 0.16); }
    .form-error                     { background-color: rgba(220, 53, 69, 0.18); color: #ff8a86; }
    .verify-banner {
        background-color: rgba(232, 116, 59, 0.12);
        border-color: rgba(232, 116, 59, 0.3);
    }

    .badge.verified                 { background-color: rgba(43, 157, 110, 0.2); color: #7fd3ad; }
    .badge.unverified               { background-color: rgba(232, 116, 59, 0.2); color: #f4a26b; }
    .badge.coming-soon              { background-color: rgba(58, 144, 223, 0.18); color: #9cc6f0; }

    /* Account danger section */
    .account-section--danger {
        background-color: rgba(179, 38, 30, 0.1);
        border-color: rgba(179, 38, 30, 0.3);
    }
    .account-section--danger h2,
    .danger-link,
    .danger-link:hover              { color: #ff8a86 !important; }

    /* Active plan outline */
    .pricing-plan.current           { outline-color: #7fd3ad; }

    /* Apps page hero icon shadow softens against dark bg */
    .app-icon                       { box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4); }

    /* Footer copyright color stays subtle */
    .footer-copyright               { color: #6a6a6a; }
}

/* Email obfuscation — address is assembled from data attributes, never in raw HTML */
.obf-email::before { content: attr(data-u); }
.obf-email::after  { content: "@" attr(data-d); }


/* ===== Warning banner (past-due payments) — theme-aware ===== */
.banner--warning {
    background: rgba(240, 180, 108, 0.12);
    border-color: rgba(240, 180, 108, 0.5);
}

@media (prefers-color-scheme: dark) {
    .banner--warning {
        background: rgba(240, 180, 108, 0.08);
        border-color: rgba(240, 180, 108, 0.3);
    }
}


/* ===== Confirm modal ===== */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 999;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.modal-overlay.is-open {
    display: flex;
}

.modal-dialog {
    background: var(--bg);
    border-radius: 16px;
    padding: 36px;
    max-width: 440px;
    width: 100%;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.2);
}

.modal-dialog h3 {
    font-family: "ClashDisplay-Bold", Arial;
    font-size: 1.4rem;
    color: var(--heading);
    margin-bottom: 12px;
    line-height: 1.2;
}

.modal-dialog p {
    color: var(--text);
    line-height: 1.55;
    margin-bottom: 28px;
    font-size: 0.95rem;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 14px;
    align-items: center;
}

.modal-cancel {
    background: transparent;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 0.95rem;
    color: var(--text);
    font-weight: 500;
    padding: 10px 16px;
    border-radius: 8px;
    transition: background 0.15s;
}

.modal-cancel:hover {
    background: var(--bg-soft);
}

@media (max-width: 600px) {
    .modal-dialog {
        padding: 28px 22px;
    }
}


/* ===== Country combobox ===== */
.country-combobox {
    position: relative;
}

.country-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    z-index: 200;
    max-height: 220px;
    overflow-y: auto;
    list-style: none;
    padding: 6px;
    margin: 0;
}

.country-dropdown.is-open {
    display: block;
}

.country-dropdown li {
    padding: 9px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.93rem;
    color: var(--heading);
    transition: background 0.1s;
}

.country-dropdown li:hover,
.country-dropdown li.kbd-active {
    background: var(--bg-soft);
}

.country-dropdown li.no-results {
    color: var(--text);
    cursor: default;
    font-style: italic;
}


/* ===== Card expiry warning badge ===== */
.badge--expiry-warn {
    background: rgba(232, 116, 59, 0.14);
    color: #c25817;
}

.badge--expired {
    background: rgba(220, 53, 69, 0.12);
    color: #b3261e;
}

@media (prefers-color-scheme: dark) {
    .badge--expiry-warn { color: #f4a26b; }
    .badge--expired     { color: #ff8a86; }
}


/* ===== Invoice history list ===== */
.invoice-amount {
    font-variant-numeric: tabular-nums;
    font-weight: 600;
    color: var(--heading);
}


/* ===== Password strength indicator ===== */
.pw-strength {
    margin-top: 8px;
}

.pw-strength-bar {
    display: flex;
    gap: 4px;
    height: 4px;
    margin-bottom: 8px;
}

.pw-strength-bar span {
    flex: 1;
    border-radius: 2px;
    background: var(--border);
    transition: background 0.2s;
}

.pw-strength-bar.strength-1 span:nth-child(1)                        { background: #dc3545; }
.pw-strength-bar.strength-2 span:nth-child(-n+2)                     { background: #e8743b; }
.pw-strength-bar.strength-3 span:nth-child(-n+3)                     { background: #f0b46c; }
.pw-strength-bar.strength-4 span:nth-child(-n+4)                     { background: #2b9d6e; }

.pw-strength-rules {
    display: flex;
    flex-direction: column;
    gap: 3px;
    font-size: 0.8rem;
    color: var(--text);
}

.pw-strength-rules li {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 6px;
}

.pw-strength-rules li::before {
    content: '✗';
    color: var(--border);
    font-size: 0.75rem;
    width: 12px;
    text-align: center;
    flex-shrink: 0;
}

.pw-strength-rules li.met::before {
    content: '✓';
    color: #2b9d6e;
}

@media (prefers-color-scheme: dark) {
    .pw-strength-bar.strength-4 span:nth-child(-n+4) { background: #7fd3ad; }
    .pw-strength-rules li.met::before                { color: #7fd3ad; }
}