/* ═══════════════════════════════════════════════════════════════════════
   GituHost Design System (2026-09-29) — শুধু ভিজ্যুয়াল স্তর
   ───────────────────────────────────────────────────────────────────────
   style.css-এর পরে লোড হয় (পাবলিক · ড্যাশবোর্ড · অ্যাডমিন তিন হেডারেই)।
   কোনো PHP/ডাটাবেজ/API আচরণ বদলায় না — বিদ্যমান ক্লাসগুলোকে (btn, card,
   form-*, badge, data-table) একই রং/টাইপোগ্রাফি/স্পেসিং/রেডিয়াস/শ্যাডো
   নিয়মে আনে, আর ট্রানজিশন, ফোকাস, লোডিং, ভ্যালিডেশন ফিডব্যাক যোগ করে।
   থিম (includes/theme.php) বদলালে --primary / --t-primary অনুযায়ী রং মানায়।
   ═══════════════════════════════════════════════════════════════════════ */

:root {
    /* রং — থিমের প্রাইমারি থাকলে সেটিই */
    --ds-primary:       var(--t-primary, var(--primary, #16a34a));
    --ds-primary-dark:  var(--t-primary-dark, var(--primary-dark, #15803d));
    --ds-primary-soft:  color-mix(in srgb, var(--ds-primary) 12%, transparent);
    --ds-text:          #111827;
    --ds-text-soft:     #4b5563;
    --ds-muted:         #6b7280;
    --ds-border:        #e5e7eb;
    --ds-border-strong: #d1d5db;
    --ds-surface:       #ffffff;
    --ds-surface-alt:   #f9fafb;
    --ds-success: #16a34a; --ds-warning: #d97706; --ds-danger: #dc2626; --ds-info: #2563eb;

    /* আকার */
    --ds-radius-sm: 8px;
    --ds-radius:    12px;
    --ds-radius-lg: 16px;
    --ds-shadow-sm: 0 1px 2px rgba(16, 24, 40, .06);
    --ds-shadow:    0 1px 3px rgba(16, 24, 40, .08), 0 1px 2px rgba(16, 24, 40, .04);
    --ds-shadow-md: 0 8px 20px -6px rgba(16, 24, 40, .14);
    --ds-shadow-lg: 0 18px 40px -12px rgba(16, 24, 40, .25);
    --ds-ring:      0 0 0 3px color-mix(in srgb, var(--ds-primary) 25%, transparent);
    --ds-ease:      cubic-bezier(.2, .8, .2, 1);
}

/* ── টাইপোগ্রাফি ও বেস ───────────────────────────────────────────────── */
html { -webkit-text-size-adjust: 100%; }
body { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
img, svg, video { max-width: 100%; }
::selection { background: var(--ds-primary-soft); }

:where(a, button, input, select, textarea, [tabindex]):focus-visible {
    outline: 2px solid var(--ds-primary);
    outline-offset: 2px;
    border-radius: 6px;
}

/* স্লিম স্ক্রলবার */
* { scrollbar-width: thin; scrollbar-color: #cbd5e1 transparent; }
*::-webkit-scrollbar { width: 8px; height: 8px; }
*::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 99px; }
*::-webkit-scrollbar-track { background: transparent; }

/* ── বাটন ───────────────────────────────────────────────────────────── */
.btn {
    border-radius: var(--ds-radius-sm);
    font-weight: 600;
    line-height: 1.25;
    min-height: 2.375rem;
    transition: background-color .18s var(--ds-ease), border-color .18s var(--ds-ease),
                color .18s var(--ds-ease), box-shadow .18s var(--ds-ease), transform .12s var(--ds-ease);
    -webkit-tap-highlight-color: transparent;
}
.btn.text-xs { min-height: 2rem; padding: .375rem .7rem; }
.btn:active:not(:disabled) { transform: translateY(1px) scale(.99); }
.btn-primary { background: var(--ds-primary); box-shadow: var(--ds-shadow-sm); }
.btn-primary:hover:not(:disabled) { background: var(--ds-primary-dark); box-shadow: var(--ds-shadow-md); }
.btn-outline { border-color: var(--ds-border-strong); color: #374151; }
.btn-outline:hover:not(:disabled) { border-color: var(--ds-primary); color: var(--ds-primary-dark); background: var(--ds-primary-soft); }
.btn-danger:hover:not(:disabled) { box-shadow: var(--ds-shadow-md); }

/* লোডিং অবস্থা (ui.js — ফর্ম সাবমিটে) */
.btn.is-loading, button.is-loading { position: relative; color: transparent !important; pointer-events: none; }
.btn.is-loading::after, button.is-loading::after {
    content: ""; position: absolute; inset: 0; margin: auto; width: 1.1em; height: 1.1em;
    border: 2px solid currentColor; border-color: rgba(255,255,255,.9) rgba(255,255,255,.9) transparent transparent;
    border-radius: 50%; animation: ds-spin .7s linear infinite;
}
.btn-outline.is-loading::after, button.is-loading:not(.btn-primary):not(.btn-danger)::after {
    border-color: var(--ds-primary) var(--ds-primary) transparent transparent;
}
@keyframes ds-spin { to { transform: rotate(360deg); } }

/* ── কার্ড ──────────────────────────────────────────────────────────── */
.card {
    border-radius: var(--ds-radius);
    border-color: var(--ds-border);
    box-shadow: var(--ds-shadow);
    transition: box-shadow .2s var(--ds-ease), border-color .2s var(--ds-ease);
}
a.card:hover, .card.is-hoverable:hover { box-shadow: var(--ds-shadow-md); border-color: #d9dee6; }

/* ── ফর্ম ───────────────────────────────────────────────────────────── */
.form-input, .form-select, .form-textarea {
    border-radius: var(--ds-radius-sm);
    border-color: var(--ds-border-strong);
    background-color: #fff;
    min-height: 2.5rem;
    font-size: .9rem;
    transition: border-color .15s var(--ds-ease), box-shadow .15s var(--ds-ease), background-color .15s;
}
.form-textarea { min-height: 5rem; }
.form-input:hover:not(:focus):not(:disabled), .form-select:hover:not(:focus):not(:disabled),
.form-textarea:hover:not(:focus):not(:disabled) { border-color: #9ca3af; }
.form-input:focus, .form-select:focus, .form-textarea:focus { border-color: var(--ds-primary); box-shadow: var(--ds-ring); }
.form-input:disabled, .form-select:disabled, .form-textarea:disabled { background: #f3f4f6; color: #9ca3af; cursor: not-allowed; }
.form-input::placeholder, .form-textarea::placeholder { color: #9ca3af; }
/* ভ্যালিডেশন ফিডব্যাক — ইউজার টাইপ করার পর ভুল হলে (পেজ লোডেই লাল দেখায় না) */
.form-input:user-invalid, .form-select:user-invalid, .form-textarea:user-invalid {
    border-color: var(--ds-danger);
    box-shadow: 0 0 0 3px rgba(220, 38, 38, .12);
}
.form-label { font-weight: 600; color: #374151; }
input[type=checkbox], input[type=radio] { accent-color: var(--ds-primary); }

/* ── ব্যাজ (স্ট্যাটাস রং-কোড) ───────────────────────────────────────── */
.badge {
    gap: .3rem; font-weight: 600; line-height: 1.35; letter-spacing: .01em;
    padding: .2rem .65rem; border: 1px solid transparent; white-space: nowrap;
}
.badge-success { border-color: #bbf7d0; }
.badge-warning { border-color: #fde68a; }
.badge-danger  { border-color: #fecaca; }
.badge-info    { border-color: #bfdbfe; }
.badge-neutral { border-color: #e5e7eb; }

/* ── টেবিল ──────────────────────────────────────────────────────────── */
.data-table { border-collapse: separate; border-spacing: 0; }
.data-table thead th { font-size: .72rem; letter-spacing: .04em; font-weight: 700; color: #6b7280; white-space: nowrap; }
.data-table tbody tr { transition: background-color .12s; }
.data-table tbody td { vertical-align: middle; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.ds-table-scroll { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
/* খালি অবস্থা (colspan সহ একক সারি) */
.data-table tbody td[colspan] { padding: 2.5rem 1rem; color: #9ca3af; text-align: center; }

/* ── টুলটিপ (আইকন-বাটন — ui.js title → data-tip) ──────────────────────── */
[data-tip] { position: relative; }
[data-tip]::after {
    content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 8px);
    transform: translate(-50%, 4px); background: #111827; color: #fff; font-size: .72rem; font-weight: 500;
    line-height: 1.3; padding: .35rem .55rem; border-radius: 6px; white-space: nowrap; pointer-events: none;
    opacity: 0; transition: opacity .15s, transform .15s; z-index: 70; box-shadow: var(--ds-shadow-md);
}
[data-tip]:hover::after, [data-tip]:focus-visible::after { opacity: 1; transform: translate(-50%, 0); }
@media (hover: none) { [data-tip]::after { display: none; } }

/* ── ফ্ল্যাশ মেসেজ / টোস্ট ───────────────────────────────────────────── */
.toast { border-radius: var(--ds-radius-sm); box-shadow: var(--ds-shadow-lg); animation: ds-in .25s var(--ds-ease); }
@keyframes ds-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }

/* ── অ্যাডমিন সাইডবার — ডেস্কটপে ছোট করা যায় (ui.js টগল) ───────────────── */
@media (min-width: 1024px) {
    body.ds-sb-collapsed aside.w-64 { width: 4.5rem; }
    body.ds-sb-collapsed aside.w-64 nav a > span,
    body.ds-sb-collapsed aside.w-64 nav .px-4.pt-2 { display: none; }
    body.ds-sb-collapsed aside.w-64 nav a { justify-content: center; padding-left: 0; padding-right: 0; position: relative; }
    body.ds-sb-collapsed aside.w-64 nav a > i { width: auto; font-size: 1.05rem; }
    body.ds-sb-collapsed aside.w-64 > div:first-child .flex { justify-content: center; }
    body.ds-sb-collapsed aside.w-64 > div:first-child .flex > div { display: none; }
    body.ds-sb-collapsed .lg\:ml-64 { margin-left: 4.5rem; }
    aside.w-64, .lg\:ml-64 { transition: width .2s var(--ds-ease), margin-left .2s var(--ds-ease); }
}
.ds-sb-toggle { display: none; }
@media (min-width: 1024px) {
    .ds-sb-toggle { display: inline-flex; align-items: center; justify-content: center; width: 2.25rem; height: 2.25rem;
                    border-radius: 8px; color: #6b7280; transition: background-color .15s, color .15s; }
    .ds-sb-toggle:hover { background: #f3f4f6; color: #111827; }
}

/* ── মোবাইল (≤ 400px) — হেডারের ডান অংশ স্ক্রিনের বাইরে যেত (☰ কেটে যেত) ── */
@media (max-width: 400px) {
    nav .container.mx-auto.px-4, header .container.mx-auto.px-4 { padding-left: .75rem; padding-right: .75rem; }
    /* (2026-10-04) প্রোফাইলের নাম navbar থেকে সরানোয় জায়গা হয়েছে — লোগোর পাশে সাইটের নামও থাকে, ডেস্কটপের মতোই */
    nav .h-16 > a.flex.items-center span.text-xl { font-size: 1.05rem; }
    nav .h-16 .flex.items-center.gap-3 { gap: .25rem; }
    nav .h-16 img.h-10 { height: 2.1rem; }
}

/* ── মোশন কমাতে চাইলে ─────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ═══════════════════════════════════════════════════════════════════════
   MOBILE LAYER (2026-10-03) — শুধু ছোট স্ক্রিন। প্রতিটি নিয়ম max-width
   media query-র ভেতরে, তাই ডেস্কটপ (≥1024px) হুবহু আগের মতো থাকে।
   কোনো PHP/HTML/ফাংশন বদলায় না।
   ═══════════════════════════════════════════════════════════════════════ */

/* ── ১. ড্যাশবোর্ডের মোবাইল মেনু থেকে "My Services" লুকানো ─────────────
   মোবাইল মেনু (hamburger) শুধু < 1024px-এ থাকে। ড্যাশবোর্ড হেডারের মেনুতে
   logout লিংক থাকে না, পাবলিক হেডারের মেনুতে থাকে — আর পাবলিক মেনুতে একই
   লিংকটি "Web Hosting" নামে আছে, তাই সেটি অক্ষত রাখতে এই পার্থক্য দিয়ে বাছা হয়। */
@media (max-width: 1023.98px) {
    nav div[x-show="mobileOpen"]:not(:has(a[href$="/logout.php"])) > a[href$="/dashboard/services.php"] { display: none !important; }
}

/* ── ২. লেআউট ভাঙা ঠেকানো (< 1024px): grid-এর ভেতরের চওড়া টেবিল/কনটেন্ট
   গোটা কলামকে স্ক্রিনের বাইরে ঠেলে দিত (ড্যাশবোর্ড হোম, ইনভয়েস, Wallet) ── */
@media (max-width: 1023.98px) {
    .grid > * { min-width: 0; }
    .flex > .flex-1 { min-width: 0; }
    main, .container { overflow-wrap: anywhere; }
    main table, .container table { overflow-wrap: normal; }
}

/* ── ৩. নেভিগেশন (hamburger মেনু) ─────────────────────────────────────── */
@media (max-width: 1023.98px) {
    nav div[x-show="mobileOpen"] {
        max-height: calc(100vh - 4rem); max-height: calc(100dvh - 4rem);
        overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
    }
    nav div[x-show="mobileOpen"] > a {
        display: flex; align-items: center; gap: .5rem;
        min-height: 44px; padding: .65rem .9rem; border-radius: 10px;
        font-size: .95rem; font-weight: 500;
        transition: background-color .15s;
    }
    nav div[x-show="mobileOpen"] > a:active { background: rgba(255,255,255,.16); }
    nav div[x-show="mobileOpen"] > a.ds-active {
        background: rgba(255,255,255,.16); font-weight: 700;
        box-shadow: inset 3px 0 0 #86efac;
    }
    /* menu খোলা/বন্ধ — x-transition-এর সাথে নরম স্লাইড */
    nav div[x-show="mobileOpen"].transition { transform-origin: top; }
    /* hamburger ও হেডারের আইকন বাটন — আঙুলে চাপার মতো আকার */
    nav button.lg\:hidden, header button.lg\:hidden {
        min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center;
    }
    /* অ্যাডমিন মোবাইল সাইডবার */
    aside.lg\:hidden nav a { min-height: 44px; }
}

/* ── ৪. মোবাইল (≤ 768px) ─────────────────────────────────────────────── */
@media (max-width: 768px) {
    html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

    /* টাইপোগ্রাফি */
    body { font-size: 15px; line-height: 1.6; }
    p, li, td, label { line-height: 1.6; }
    main .text-xs, .container .text-xs { font-size: .78rem; line-height: 1.5; }
    main .text-sm, .container .text-sm { font-size: .875rem; }
    main h1, main .text-3xl, .container h1.text-3xl { font-size: 1.5rem; line-height: 1.3; }
    main .text-4xl { font-size: 1.75rem; line-height: 1.25; }
    main .text-5xl, main .text-6xl { font-size: 2rem; line-height: 1.2; }
    main h2.text-2xl, main h1.text-2xl, main .text-2xl { font-size: 1.3rem; line-height: 1.35; }
    main .text-xl { font-size: 1.15rem; }

    /* স্পেসিং — কিনারা থেকে কমপক্ষে ১৬px */
    .container.mx-auto { padding-left: 1rem; padding-right: 1rem; }
    main.container { padding-top: 1rem; padding-bottom: 1.5rem; }
    .card.p-6, .card.p-8, .card .p-6, .card.md\:p-8 { padding: 1.125rem; }
    .card.p-5 { padding: 1rem; }
    .card { border-radius: 14px; }

    /* কার্ড ও স্ট্যাট — পূর্ণ প্রস্থে স্তূপ, স্ট্যাট কার্ড ২ কলামে */
    .grid.md\:grid-cols-3:has(> a.card.border-l-4),
    .grid.md\:grid-cols-4:has(> .card),
    .grid.lg\:grid-cols-4:has(> .card > .text-2xl),
    .grid.sm\:grid-cols-4:has(> .card) {
        grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem;
    }
    .grid.md\:grid-cols-3:has(> a.card.border-l-4) > :last-child:nth-child(odd) { grid-column: 1 / -1; }
    .grid.md\:grid-cols-3 > a.card.border-l-4 .text-3xl { font-size: 1.6rem; }

    /* ফর্ম — পূর্ণ প্রস্থ, ১৬px ফন্ট (iOS-এ ইনপুটে জুম ঠেকায়), আঙুলে চাপার মতো উঁচু */
    .form-input, .form-select, .form-textarea,
    main input[type=text], main input[type=email], main input[type=password], main input[type=tel],
    main input[type=number], main input[type=search], main input[type=url], main select, main textarea {
        font-size: 16px; min-height: 46px;
    }
    main textarea, .form-textarea { min-height: 6rem; }
    .form-input, .form-select, .form-textarea { width: 100%; max-width: 100%; }
    .form-label, main label.block { font-size: .9rem; font-weight: 600; margin-bottom: .35rem; display: inline-block; }
    input[type=checkbox], input[type=radio] { width: 1.15rem; height: 1.15rem; }

    /* বাটন — কমপক্ষে ৪৪px */
    .btn { min-height: 44px; padding-left: 1rem; padding-right: 1rem; }
    .btn.text-xs { min-height: 40px; padding: .45rem .8rem; }
    /* ফর্মের মূল সাবমিট বাটন — পূর্ণ প্রস্থ (ইনলাইন/টেবিলের ছোট ফর্ম বাদে) */
    main form[class*="space-y"] > button[type=submit]:not(.text-xs),
    main form[class*="space-y"] > button:not([type]):not(.text-xs),
    main form[class*="space-y"] > div:last-child > button[type=submit]:only-child,
    main form[class*="space-y"] > div:last-child > button:not([type]):only-child {
        width: 100%; min-height: 48px; justify-content: center;
    }
    td form button, td form button[type=submit] { width: auto !important; min-height: 40px; }
    /* ডোমেইন সার্চ বক্স — ইনপুট সঙ্কুচিত হতে পারে, বাটন বাক্সের ভেতরেই থাকে */
    .dom-search-wrap input { min-width: 0; }
    .dom-search-wrap { padding-left: 16px; }
    .dom-search-wrap .dom-search-btn { flex: 0 0 auto; padding: 11px 18px; }
    /* পাশাপাশি অ্যাকশন বাটন — সমান ভাগে পূর্ণ প্রস্থ */
    .card .flex.flex-wrap:not(.flex-col).gap-2 > .btn, .card .flex:not(.flex-col).gap-2 > .btn:not(.text-xs) { flex: 1 1 auto; justify-content: center; }
    table.ds-cards > tbody > tr > td[data-label=""] > a.btn:only-child { display: flex; width: 100%; justify-content: center; }
    /* এক সারির সার্চ/ফিল্টার ফর্ম — ইনপুট পুরো লাইন, বাটন পরের লাইনে */
    main form.flex { flex-wrap: wrap; width: 100%; margin-left: 0; }
    main form.flex > input.form-input, main form.flex > input.flex-1, main form.flex > .flex-1 { flex: 1 1 11rem; width: auto; }

    /* এরর/সাফল্যের বার্তা */
    .bg-red-50.border-l-4, .bg-green-50.border-l-4, .bg-amber-50.border-l-4, .bg-blue-50.border-l-4 {
        font-size: .9rem; line-height: 1.55; padding: .8rem .9rem; border-radius: 10px;
    }
    main .text-red-600.text-xs, main .text-red-600.text-sm, main p.text-red-600 { font-size: .85rem; margin-top: .3rem; }

    /* টেবিল → কার্ড (ui.js প্রতিটি ঘরে কলামের নাম data-label হিসেবে বসায়) */
    table.ds-cards, table.ds-cards > tbody, table.ds-cards > tbody > tr, table.ds-cards > tbody > tr > td,
    table.ds-cards > tfoot, table.ds-cards > tfoot > tr, table.ds-cards > tfoot > tr > td { display: block; width: 100%; }
    table.ds-cards > thead { display: none; }
    table.ds-cards { border: 0; min-width: 0 !important; }
    .ds-table-scroll:has(> table.ds-cards) { overflow: visible; }
    table.ds-cards > tbody > tr {
        background: #fff; border: 1px solid var(--ds-border); border-radius: 12px;
        box-shadow: var(--ds-shadow-sm); padding: .35rem .9rem; margin: 0 0 .75rem;
    }
    /* ঘর: বাঁয়ে কলামের নাম (float), ডানে মান — একাধিক লাইনের মান (নাম + ইমেইল) নিচে নিচে থাকে */
    table.ds-cards > tbody > tr > td {
        display: flow-root !important;
        padding: .55rem 0 !important; border: 0 !important; border-bottom: 1px dashed #eef0f3 !important;
        text-align: right !important; white-space: normal !important; font-size: .9rem; line-height: 1.5;
    }
    table.ds-cards > tbody > tr > td:last-child { border-bottom: 0 !important; }
    table.ds-cards > tbody > tr > td::before {
        content: attr(data-label); float: left; max-width: 42%; margin: .1rem .75rem 0 0;
        text-align: left; font-size: .72rem; font-weight: 700; letter-spacing: .03em; line-height: 1.4;
        text-transform: uppercase; color: #6b7280;
    }
    table.ds-cards > tbody > tr > td[data-label=""]::before { display: none; }
    table.ds-cards > tbody > tr > td > :is(div, form, p).flex,
    table.ds-cards > tbody > tr > td > :is(div, p).inline-flex { justify-content: flex-end; flex-wrap: wrap; }
    table.ds-cards > tbody > tr > td > * { max-width: 100%; }
    table.ds-cards > tbody > tr > td > form { display: inline-block; }
    table.ds-cards > tbody > tr > td[colspan] { display: block; text-align: center !important; border: 0 !important; }
    table.ds-cards > tbody > tr > td[colspan]::before { display: none; }
    table.ds-cards > tbody > tr:has(> td[colspan]:only-child) { box-shadow: none; }
    table.ds-cards > tfoot > tr > td { text-align: right !important; padding: .4rem .25rem !important; }
    table.ds-cards > tfoot > tr > td:empty { display: none; }
    table.ds-cards > tbody > tr:hover { background: #fff; }

    /* কার্ড না হওয়া চওড়া টেবিল (দামের তালিকা ইত্যাদি) — নিজের ভেতরে স্ক্রল, পাতা নয় */
    .dom-pricing-table, .tldp-table, main table:not(.ds-cards) { max-width: 100%; }
    .dom-pricing-table, .tldp-table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }

    /* মডাল/পপআপ — নিচ থেকে ওঠা bottom sheet; বন্ধের বাটন আঙুলের কাছে।
       সাইটে দুই ধরনের মডাল: Tailwind ক্লাস (.fixed.inset-0…) ও inline style (position:fixed; inset:0) */
    :is(.fixed.inset-0.items-center.justify-center, :is([style*="position:fixed"],[style*="position: fixed"]):is([style*="inset:0"],[style*="inset: 0"]):is([style*="align-items:center"],[style*="align-items: center"])):not(nav *) {
        align-items: flex-end !important; padding: 0 !important;
    }
    :is(.fixed.inset-0.items-center.justify-center, :is([style*="position:fixed"],[style*="position: fixed"]):is([style*="inset:0"],[style*="inset: 0"]):is([style*="align-items:center"],[style*="align-items: center"])):not(nav *)
      > :is(div, form):is(.bg-white, [style*="background:#fff"], [style*="background: #fff"], [style*="background:white"]) {
        width: 100% !important; max-width: 100% !important; margin: 0 !important;
        border-radius: 20px 20px 0 0 !important;
        max-height: 92vh; max-height: 92dvh; overflow-y: auto; overscroll-behavior: contain;
        padding-bottom: calc(1.25rem + env(safe-area-inset-bottom)) !important;
        animation: ds-sheet-up .22s var(--ds-ease);
    }
    :is(.fixed.inset-0.items-center.justify-center, :is([style*="position:fixed"],[style*="position: fixed"]):is([style*="inset:0"],[style*="inset: 0"]):is([style*="align-items:center"],[style*="align-items: center"])):not(nav *)
      > :is(div, form):is(.bg-white, [style*="background:#fff"], [style*="background: #fff"], [style*="background:white"])::before {
        content: ""; display: block; width: 42px; height: 5px; border-radius: 99px;
        background: #d1d5db; margin: -.4rem auto .9rem;
    }
    :is(.fixed.inset-0.items-center.justify-center, :is([style*="position:fixed"],[style*="position: fixed"]):is([style*="inset:0"],[style*="inset: 0"]):is([style*="align-items:center"],[style*="align-items: center"])):not(nav *)
      :is(.flex.justify-end, [style*="justify-content:flex-end"]) > :is(.btn, button) { flex: 1 1 0; min-height: 48px; justify-content: center; }
    /* মডালের ✕ বাটন — বড় স্পর্শ-এলাকা */
    :is(.fixed.inset-0.items-center.justify-center, :is([style*="position:fixed"],[style*="position: fixed"]):is([style*="inset:0"],[style*="inset: 0"])):not(nav *) button:is([aria-label*="lose" i], [aria-label*="বন্ধ"]),
    :is(.fixed.inset-0.items-center.justify-center, :is([style*="position:fixed"],[style*="position: fixed"]):is([style*="inset:0"],[style*="inset: 0"])):not(nav *) button:has(> i.fa-times:only-child),
    :is(.fixed.inset-0.items-center.justify-center, :is([style*="position:fixed"],[style*="position: fixed"]):is([style*="inset:0"],[style*="inset: 0"])):not(nav *) button[onclick*="close" i]:not(.btn),
    :is(.fixed.inset-0.items-center.justify-center, :is([style*="position:fixed"],[style*="position: fixed"]):is([style*="inset:0"],[style*="inset: 0"])):not(nav *) > * > :first-child > button:last-child:not(.btn) {
        min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center;
    }

    /* ছবি ও আইকন */
    img, svg, video, iframe { max-width: 100%; height: auto; }
    main a:has(> i.fas:only-child), main button:has(> i.fas:only-child) { min-width: 40px; min-height: 40px; display: inline-flex; align-items: center; justify-content: center; }

    /* পারফরম্যান্স — অপ্রয়োজনীয় অ্যানিমেশন কমানো */
    .card, a.card, .data-table tbody tr { transition: none; }
    .hover\:shadow-lg:hover, a.card:hover { box-shadow: var(--ds-shadow); }
    [class*="hover:-translate-y"]:hover, [class*="hover:scale"]:hover { transform: none !important; }
    .animate-bounce { animation: none; }
}
@keyframes ds-sheet-up { from { transform: translateY(24px); opacity: .6; } to { transform: none; opacity: 1; } }

/* খুব ছোট ফোন (≤ 360px) */
@media (max-width: 360px) {
    body { font-size: 14.5px; }
    .container.mx-auto { padding-left: 1rem; padding-right: 1rem; }
    .grid.md\:grid-cols-3:has(> a.card.border-l-4) > a.card .text-3xl { font-size: 1.4rem; }
}

/* ═══════════════════════════════════════════════════════════════════════
   MOBILE LAYER ২ (2026-10-03) — শুধু ≤ 768px; ডেস্কটপ অপরিবর্তিত
   ═══════════════════════════════════════════════════════════════════════ */

/* ── ড্যাশবোর্ড স্ট্যাট সংখ্যা: ফোন dark mode-এ থাকলে Tailwind-এর dark:text-white
   সংখ্যাগুলো সাদা করে দিত, অথচ কার্ড সাদাই থাকে — তাই সংখ্যা অদৃশ্য হয়ে যেত ── */
@media (max-width: 768px) and (prefers-color-scheme: dark) {
    body:not(.dark) .grid > a.card .dark\:text-white { color: #1f2937; }
}

@media (max-width: 768px) {
    /* ── Domain details (dashboard/domain-manage.php) ──────────────────── */
    .card.p-5:has(> .flex h1.font-mono) {
        padding: 1.1rem 1rem 1rem;
        background: linear-gradient(180deg, #f0fdf4 0%, #fff 7.5rem);
        border-color: #dcfce7;
    }
    .card.p-5 > .flex.items-start.justify-between:has(h1.font-mono) {
        flex-direction: column; align-items: stretch; gap: .9rem;
    }
    .card.p-5 > .flex:has(h1.font-mono) > .flex-1 { width: 100%; }
    /* ফেরত লিংক — ছোট chip */
    .card.p-5 > .flex:has(h1.font-mono) > .flex-1 > a:first-child {
        display: inline-flex; align-items: center; gap: .35rem;
        font-size: .78rem; font-weight: 600; color: #15803d;
        background: #fff; border: 1px solid #bbf7d0; border-radius: 999px; padding: .3rem .75rem;
    }
    /* ডোমেইন নাম — যত বড় সম্ভব, এক লাইনে; খুব লম্বা হলে শব্দ ভেঙে নিচে যায়, বাইরে নয় */
    .card.p-5 h1.font-mono {
        font-size: clamp(1.1rem, 5.6vw, 1.5rem); line-height: 1.25; letter-spacing: -.02em;
        margin-top: .7rem; color: #052e16;
        overflow-wrap: break-word; word-break: break-word; max-width: 100%;
    }
    /* স্ট্যাটাস ব্যাজ — ছোট, পাশাপাশি, ভাঙে না */
    .card.p-5 > .flex:has(h1.font-mono) > .flex-1 > .flex.items-center.gap-2 { gap: .4rem; margin-top: .6rem; }
    .card.p-5 > .flex:has(h1.font-mono) > .flex-1 > .flex.items-center > span.rounded-full {
        display: inline-flex; align-items: center; white-space: nowrap;
        font-size: .72rem; font-weight: 600; line-height: 1; padding: .38rem .7rem;
    }
    /* EPP Code ও Renew — পাশাপাশি সমান দুই ভাগে, ছোট ও পরিপাটি */
    .card.p-5 > .flex:has(h1.font-mono) > .flex.gap-2.flex-wrap {
        display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .5rem; width: 100%;
    }
    .card.p-5 > .flex:has(h1.font-mono) > .flex.gap-2.flex-wrap > form { display: block; }
    .card.p-5 > .flex:has(h1.font-mono) > .flex.gap-2.flex-wrap > :is(form > .btn, .btn, span),
    .card.p-5 > .flex:has(h1.font-mono) > .flex.gap-2.flex-wrap > form > button {
        width: 100%; min-height: 40px; justify-content: center; display: inline-flex; align-items: center; gap: .35rem;
        font-size: .8rem; padding: .45rem .5rem; border-radius: 10px; white-space: nowrap;
    }
    .card.p-5 > .flex:has(h1.font-mono) > .flex.gap-2.flex-wrap > .w-full { grid-column: 1 / -1; margin-top: 0; }
    /* Registration / Expiry / মূল্য — ছোট কার্ড */
    .card.p-5:has(> .flex h1.font-mono) > .grid.border-t {
        grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .5rem;
        border-top: 0; margin-top: 1rem; padding-top: 0;
    }
    /* তৃতীয়টি (মূল্য) পুরো সারিতে — বাঁয়ে লেবেল, ডানে অঙ্ক */
    .card.p-5:has(> .flex h1.font-mono) > .grid.border-t > div:nth-child(3) {
        grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between;
    }
    .card.p-5:has(> .flex h1.font-mono) > .grid.border-t > div:nth-child(3) > div:last-child { margin-top: 0; font-size: .95rem; color: #15803d; }
    .card.p-5:has(> .flex h1.font-mono) > .grid.border-t > div {
        background: #fff; border: 1px solid #e5e7eb; border-radius: 12px;
        padding: .65rem .7rem; box-shadow: 0 1px 2px rgba(16,24,40,.05);
    }
    .card.p-5:has(> .flex h1.font-mono) > .grid.border-t > div > div:first-child {
        font-size: .68rem; text-transform: uppercase; letter-spacing: .03em; font-weight: 700; color: #6b7280; line-height: 1.3;
    }
    .card.p-5:has(> .flex h1.font-mono) > .grid.border-t > div > div:last-child {
        font-size: .86rem; font-weight: 700; color: #111827; margin-top: .2rem; white-space: nowrap;
    }
    .card.p-5:has(> .flex h1.font-mono) > .grid.border-t > div > div.text-red-600:last-child { color: #dc2626; }
    /* এই পেজে শব্দ মাঝখানে ভাঙবে না ("REGISTRATIO N", "Edi t") — শুধু খুব লম্বা শব্দ হলে */
    .flex-1.min-w-0.space-y-4:has(h1.font-mono) { overflow-wrap: break-word; }
    .flex-1.min-w-0.space-y-4:has(h1.font-mono) :is(.btn, button, .badge) { white-space: nowrap; overflow-wrap: normal; }
    /* পেজের অন্য কার্ড — একই স্পেসিং */
    .flex-1.min-w-0.space-y-4:has(h1.font-mono) > * + * { margin-top: .85rem; }
    .flex-1.min-w-0.space-y-4:has(h1.font-mono) .card.p-5 { padding: 1rem; }

    /* ── Hosting order (order/hosting.php) — ক্যাটাগরি: উপরে আড়াআড়ি স্ক্রল chip ── */
    .card > .flex[style*="min-height:420px"] { flex-direction: column; min-height: 0 !important; }
    .card > .flex[style*="min-height:420px"] > .flex-shrink-0.border-r {
        width: 100% !important; display: flex; gap: .5rem; overflow-x: auto; overflow-y: hidden;
        border-right: 0; border-bottom: 1px solid #e5e7eb; padding: .75rem 1rem;
        scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch; scrollbar-width: none;
    }
    .card > .flex[style*="min-height:420px"] > .flex-shrink-0.border-r::-webkit-scrollbar { display: none; }
    .card > .flex[style*="min-height:420px"] > .flex-shrink-0.border-r > button {
        width: auto; flex: 0 0 auto; scroll-snap-align: start;
        border: 1.5px solid #d1d5db; border-radius: 999px; padding: .5rem .95rem; min-height: 40px;
        white-space: nowrap; font-size: .85rem; background: #fff;
        transition: background-color .2s, color .2s, border-color .2s, box-shadow .2s;
    }
    .card > .flex[style*="min-height:420px"] > .flex-shrink-0.border-r > button.bg-green-600 {
        background: #16a34a; border-color: #16a34a; color: #fff; box-shadow: 0 4px 12px rgba(22,163,74,.28);
    }
    .card > .flex[style*="min-height:420px"] > .flex-shrink-0.border-r > button > span:first-child { width: auto; }
    .card > .flex[style*="min-height:420px"] > .flex-1 { padding: 1rem; overflow: visible; }
    .card > .flex[style*="min-height:420px"] > .flex-1 > div[x-show] { animation: ds-tab-in .25s var(--ds-ease); }
    .card > .flex[style*="min-height:420px"] .grid[style*="minmax(230px"] { grid-template-columns: minmax(0, 1fr) !important; }
}
@keyframes ds-tab-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ═══════════════════════════════════════════════════════════════════════
   Navbar brand (2026-10-04) — সব প্রস্থে একই: সাইটের নাম সবুজ থিমের gradient লেখা
   ═══════════════════════════════════════════════════════════════════════ */
.ds-brand {
    font-weight: 800; letter-spacing: .02em; line-height: 1.15;
    background: linear-gradient(95deg, #ffffff 0%, #f0fdf4 30%, #86efac 62%, #22c55e 100%);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: #fff;
    filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .25));
    white-space: nowrap;
}
@media (max-width: 360px) {
    /* খুব ছোট ফোনে লোগো + নাম + আইকন এক সারিতে আঁটে (☰ কেটে যায় না) */
    nav .ds-brand { font-size: .98rem; letter-spacing: .01em; }
    nav .h-16 > a.flex.items-center.gap-2 { gap: .35rem; min-width: 0; }
    nav .h-16 button.lg\:hidden { min-width: 38px; padding-left: .35rem; padding-right: .35rem; }
    nav .h-16 .flex.items-center.gap-3 > .relative > button.rounded-full { padding-left: .3rem; padding-right: .3rem; }
}
