/* AZEE SMS Pro v9 — premium, responsive design tokens / layout polish.
 * PHP-rendered accessible markup with app-like UI; no React/Next.js runtime needed.
 * All motion respects prefers-reduced-motion. */
:root{
  --brand:#2168ee;--brand-2:#428aff;--brand-soft:#eaf2ff;
  --bg:#f4f7fd;--surface:#fff;--surface2:#f8faff;--nav:#fff;
  --stroke:#dfe8f5;--hover:#f0f5ff;--heading:#112242;--text:#253853;
  --muted:#647792;--radius:19px;
  --shadow:0 6px 28px rgba(21,57,115,.055);
  --strong-shadow:0 24px 75px rgba(26,63,125,.13);
  --v9-focus:rgba(47,117,249,.19);
  --v9-ease:cubic-bezier(.22,.68,0,1.03)
}
:root[data-theme=dark]{
  --brand:#83b4ff;--brand-2:#5d98ff;--brand-soft:#1e365a;
  --bg:#090f1d;--surface:#111b2d;--surface2:#152239;
  --nav:#101a2b;--stroke:#293c57;--hover:#1b2c49;
  --heading:#f6f9ff;--text:#dbe7f9;--muted:#a1b1cb;
  --shadow:0 15px 34px rgba(0,0,0,.17);--strong-shadow:0 30px 65px rgba(0,0,0,.33);
  --v9-focus:rgba(113,168,252,.3)
}
html{scroll-padding-top:88px;scroll-behavior:smooth}
body{background-image:radial-gradient(ellipse at 75% -30%,rgba(48,123,245,.08),transparent 50%);background-attachment:fixed;overscroll-behavior-y:contain}
::selection{background:var(--brand-soft);color:var(--heading)}
:where(h1,h2,h3,b,strong){text-wrap:pretty}
:where(button,a,input,select,textarea){-webkit-tap-highlight-color:transparent}
:where(button,a,[role=button]){touch-action:manipulation}
:where(button,a,input,select,textarea):focus-visible{outline:3px solid var(--v9-focus)!important;outline-offset:3px}
:where(button,.btn):disabled{opacity:.58;cursor:wait!important;box-shadow:none!important}
:where(input:not([type=checkbox]):not([type=radio]),textarea,select){
  color:var(--text)!important;background:var(--input,var(--surface))!important;
  border:1px solid var(--stroke)!important;min-height:45px;
  border-radius:13px!important;transition:border-color .19s ease,box-shadow .19s ease,background .2s ease;
  font-size:clamp(14px,.88vw,15px)
}
:where(input:not([type=checkbox]):not([type=radio]),textarea,select):focus{
  border-color:var(--brand-2)!important;box-shadow:0 0 0 4px var(--v9-focus)!important
}
input[type=search]{appearance:none;-webkit-appearance:none}
textarea{resize:vertical;min-height:96px;padding:13px 15px!important}
:where(label,legend){line-height:1.45}
:where(label) :is(input,select,textarea){margin-top:3px}
:where(.btn,.v5-buy-button,.v5-mode){
  border-radius:12px!important;font-weight:750!important;letter-spacing:-.008em;
  transition:transform .19s var(--v9-ease),box-shadow .2s ease,background .18s ease,border-color .18s ease
}
:where(.btn,.v5-buy-button):not(:disabled):hover{transform:translateY(-2px)}
:where(.btn,.v5-buy-button):not(:disabled):active{transform:translateY(0) scale(.984)}
.btn svg.icon{width:17px;height:17px}
.btn.primary,.v5-buy-button{background:linear-gradient(115deg,#155bea,#2b84f7)!important;color:#fff!important;
  box-shadow:0 12px 26px rgba(25,103,242,.19)!important}
.btn.primary:hover,.v5-buy-button:hover{box-shadow:0 16px 31px rgba(20,103,236,.27)!important}
.btn.secondary{background:var(--surface)!important;border-color:var(--stroke)!important}
.btn.secondary:hover{background:var(--hover)!important;border-color:var(--brand-2)!important}
.btn.busy{pointer-events:none}
:where(.panel,.metric,.auth-card,.v5-category-card,.v5-feature-card,.v5-buy-panel,.v5-hero,.az-support-shell){
  box-shadow:var(--shadow);border:1px solid var(--stroke);border-radius:var(--radius)
}
.panel{min-width:0}
.panel,.metric,.v5-feature-card,.v5-category-card{transition:box-shadow .24s ease,border-color .24s ease,transform .24s var(--v9-ease)}
:where(.panel,.metric,.v5-feature-card,.v5-category-card):hover{border-color:color-mix(in srgb,var(--brand-2) 28%,var(--stroke));box-shadow:0 15px 32px rgba(27,65,125,.085)}
.metric:hover,.v5-feature-card:hover,.v5-category-card:hover{transform:translateY(-3px)}
.metric{background:linear-gradient(150deg,var(--surface),var(--surface2))}
.page-heading{margin-bottom:25px}
.page-heading h1{font-weight:850;letter-spacing:-.045em;font-size:clamp(1.65rem,2.7vw,2.75rem)}
.page-heading p{font-size:clamp(13px,1vw,15px);line-height:1.7}
.eyebrow{letter-spacing:.11em}
/* Navigation / top bar */
.sidebar{background:var(--nav);border-right:1px solid var(--stroke);box-shadow:3px 0 28px rgba(25,64,127,.035)}
.sidebar .brand{padding:4px 10px;white-space:normal;line-height:1.15}
.brand-mark,.v5-brand-logo{background:linear-gradient(145deg,#166df7,#244dd8)!important;box-shadow:0 8px 20px rgba(26,102,230,.19)!important}
.sidebar .nav{gap:4px}.sidebar .nav>a{border:1px solid transparent;border-radius:12px;min-height:45px;letter-spacing:-.01em}
.sidebar .nav>a:hover{border-color:var(--stroke);transform:translateX(3px);background:var(--hover)}
.sidebar .nav>a.selected{color:var(--brand);border-color:color-mix(in srgb,var(--brand) 13%,var(--stroke));background:var(--brand-soft)}
.sidebar .nav svg{opacity:.92}
.sidebar-footer{margin-top:25px}
.topbar{background:color-mix(in srgb,var(--surface) 92%,transparent);backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px);box-shadow:0 3px 21px rgba(15,52,103,.035)}
.topbar-context{letter-spacing:-.025em}
.theme-toggle,.menu-toggle,.icon-button{border-radius:13px;min-height:41px;min-width:41px}
.theme-toggle:hover,.menu-toggle:hover,.icon-button:hover{border-color:var(--brand-2)}
.top-balance{background:var(--surface2);border-radius:12px}
/* Public marketplace */
.v5-public-header{position:sticky;top:0;z-index:60;border-bottom:1px solid var(--stroke);background:color-mix(in srgb,var(--surface) 94%,transparent);backdrop-filter:blur(20px);-webkit-backdrop-filter:blur(20px)}
.v5-public-layout{max-width:1700px;gap:clamp(12px,2vw,28px)}
.v5-buy-panel{background:var(--surface);border-radius:21px;align-self:start;overflow:hidden}
.v5-hero{border-radius:23px;isolation:isolate}
.v5-hero h1{letter-spacing:-.052em}
.v5-hero .btn{min-height:46px}
.v5-service-row,.v5-country-row,.v5-operator-row{border-radius:11px;transition:background .16s ease,transform .18s ease,border-color .2s ease}
.v5-service-row:hover,.v5-country-row:hover,.v5-operator-row:hover{transform:translateX(2px)}
.service-icon,.v5-service-icon{display:inline-grid;place-items:center;flex:none;overflow:hidden}
.service-icon img,.v5-service-icon img,.history-service-logo,.brand-map-row img{width:100%;height:100%;object-fit:contain;aspect-ratio:1;border-radius:8px}
.history-brand{min-width:170px}
.history-brand span{min-width:0}.history-country-flag{width:20px;height:14px;object-fit:cover;border-radius:2px;display:inline-block!important;vertical-align:middle;margin-right:2px}
.v5-country-left img{width:24px;height:17px;object-fit:cover;border-radius:3px;box-shadow:0 1px 4px rgba(0,0,0,.12)}
.service-card,.v5-category-card{isolation:isolate}
.service-card:hover{border-color:var(--brand-2)}
.stock-badge,.status{font-weight:800}
/* Customer financial history tables */
.table-wrap{max-width:100%;overflow:auto;overscroll-behavior-x:contain;scrollbar-width:thin;scrollbar-color:var(--stroke) transparent}
.table-wrap table{border-spacing:0}
.table-wrap thead{position:sticky;top:0;z-index:2}
.table-wrap th{background:var(--surface2)}
.table-wrap tbody tr:hover{background:var(--hover)}
.table-search{min-width:min(260px,100%)}
/* New cache admin */
.v9-stats-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px;margin-bottom:20px}
.v9-setting-card{display:flex;flex-direction:column;align-items:flex-start;gap:12px;padding:26px;min-height:280px}
.v9-setting-card h2{margin:0;font-size:1.15rem;letter-spacing:-.02em}
.v9-setting-card p{margin:0 0 8px;flex:1;font-size:.9rem}
.v9-setting-card .btn{width:100%;white-space:normal;text-align:center;min-height:49px}
.v9-card-symbol{display:grid;place-items:center;width:51px;height:51px;border-radius:17px;background:var(--brand-soft);color:var(--brand)}
.v9-card-symbol .icon{width:25px;height:25px}
.v9-cache-audit{padding:23px}
.v9-cache-audit h2{margin-bottom:9px}.v9-cache-audit #v9-cache-status{color:var(--text)}
/* Forms, contact, tickets, chatbot */
.auth-card{box-shadow:var(--strong-shadow)}
.auth-wrap{padding:22px 12px}.auth-card .form-stack{gap:15px}
.ticket-bubble,.az-support-message,.az-chat-msg{box-shadow:0 5px 18px rgba(31,72,131,.045)}
.az-chat-launch{background:linear-gradient(120deg,#175de5,#3a91ff);box-shadow:0 13px 34px rgba(24,99,233,.27)}
.az-chat-panel{border:1px solid var(--stroke);box-shadow:0 18px 65px rgba(8,37,87,.2)}
.az-chat-head{background:linear-gradient(120deg,#1a61e8,#3588f7)}
.az-support-shell{background:var(--surface)}
.footer,.footer-v3{background:color-mix(in srgb,var(--surface) 94%,transparent);border-top:1px solid var(--stroke)}
.footer a:hover{color:var(--brand)}
/* Motion: short entrance animations, never block interactions */
@keyframes v9Appear{from{opacity:0;transform:translateY(11px)}to{opacity:1;transform:none}}
@keyframes v9Pulse{0%,100%{opacity:1}50%{opacity:.55}}
.main>.page-heading,.public-main>.page-heading{animation:v9Appear .36s ease both}
.main>.metric-grid,.main>.v9-stats-grid{animation:v9Appear .45s .05s ease both}
.v5-feature-card,.v5-category-card{animation:v9Appear .32s ease backwards}
.btn.busy::after{animation:spin .6s linear infinite}
.skeleton{animation:shimmer 1.5s ease infinite}
/* Tablet: leave room for selection and purchase, simplify information density */
@media(max-width:1230px){.v9-stats-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.v9-setting-card{min-height:260px}.admin-layout{grid-template-columns:minmax(0,1fr)}.footer{gap:20px}}
@media(max-width:960px){.sidebar{max-width:calc(100vw - 60px);z-index:1300}.app-layout{grid-template-columns:minmax(0,1fr)}.main{padding:clamp(16px,3vw,28px)}.v5-public-layout{align-items:start}.v9-stats-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.v9-stats-grid{grid-template-columns:1fr}.v9-setting-card{min-height:unset}.v5-public-header{position:relative}.page-heading{flex-wrap:wrap}.page-heading .btn{max-width:100%;white-space:normal}.topbar{padding-inline:14px}.top-right{gap:7px}.panel{padding:clamp(16px,4vw,24px)}.footer{gap:22px}.az-chat-root{z-index:1900}}
@media(max-width:520px){body{font-size:14px}.main{padding:17px 12px 44px}.topbar{height:62px}.topbar-context{font-size:12px}.top-right .btn{font-size:12px}.top-balance{padding:6px 8px}.v5-buy-panel{border-radius:16px}.metric-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}.metric{padding:15px}.metric b{font-size:clamp(1.23rem,5vw,1.8rem)}.metric small{font-size:11px}.admin-layout,.wallet-grid,.detail-grid{grid-template-columns:minmax(0,1fr)!important}.two-cols{grid-template-columns:minmax(0,1fr)}.inline-form{flex-direction:column;align-items:stretch}.inline-form label{width:100%}.btn{max-width:100%}.az-chat-panel{max-height:calc(100dvh - 110px)}.footer{padding:22px 18px}}
@media(max-width:360px){.main{padding:13px 10px}.metric-grid{grid-template-columns:1fr!important}.topbar-context{font-size:11px}.v9-setting-card{padding:17px}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto!important}*,*::before,*::after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}
