/* ==========================================================================
   Terraplaniq — Panel "Mi Cuenta"
   Mismo sistema de diseño que terraplaniq.com (css/style.css):
   paleta Material Green, base blanca, sombras verdes suaves.
   ========================================================================== */

:root {
    --g900: #1B5E20; --g800: #2E7D32; --g700: #388E3C; --g600: #43A047;
    --g500: #4CAF50; --g400: #66BB6A; --g300: #81C784; --g200: #A5D6A7;
    --g100: #C8E6C9; --g50:  #E8F5E9;

    --primary: var(--g500);
    --primary-dark: var(--g800);
    --white: #ffffff;
    --bg-page: #f7fbf8;
    --text: #1B3A2A;
    --text-light: #4b6b58;
    --border: #e2efe6;
    --danger: #c62828;
    --danger-soft: #fdecea;
    --navy: #1e3a8a;
    --warn: #b26a00;
    --warn-soft: #fff6e5;

    --shadow-sm: 0 4px 16px rgba(27, 94, 32, 0.08);
    --shadow: 0 4px 24px rgba(27, 94, 32, 0.10);
    --radius: 14px;
    --font: 'Lufga', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Lufga del sitio (en el servidor); si no está, cae a la pila del sistema */
@font-face { font-family:'Lufga'; font-weight:400; font-style:normal; font-display:swap;
             src:url('/css/fuente%202/Fontspring-DEMO-lufga-regular.otf') format('opentype'); }
@font-face { font-family:'Lufga'; font-weight:600; font-style:normal; font-display:swap;
             src:url('/css/fuente%202/Fontspring-DEMO-lufga-semibold.otf') format('opentype'); }
@font-face { font-family:'Lufga'; font-weight:900; font-style:normal; font-display:swap;
             src:url('/css/fuente%202/Fontspring-DEMO-lufga-black.otf') format('opentype'); }

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

/* ───────── Iconos SVG (estilo SF Symbols) ───────── */
.ico { width: 1.05em; height: 1.05em; display: inline-block; vertical-align: -0.14em; flex-shrink: 0; }
html { -webkit-font-smoothing: antialiased; }
body {
    font-family: var(--font);
    background: var(--bg-page);
    color: var(--text);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ───────── Marca ───────── */
.brand { display:inline-flex; flex-direction:column; align-items:flex-end; text-decoration:none; line-height:1; }
.brand .bm-word { font-weight:900; font-size:1.5rem; letter-spacing:-0.9px; line-height:0.95; color:var(--g700); }
.brand .bm-sub  { font-weight:600; font-size:0.78rem; letter-spacing:-0.25px; color:var(--g700); }
.brand-center   { align-items:center; margin:0 auto 6px; display:flex; }

/* ───────── Barra superior ───────── */
.topbar { background: var(--white); border-bottom: 1px solid var(--border); box-shadow: var(--shadow-sm); }
.topbar-inner {
    max-width: 960px; margin: 0 auto; padding: 12px 20px;
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.topbar-user { display: flex; align-items: center; gap: 12px; }
.hello { color: var(--text-light); font-size: 0.92rem; display: inline-flex; align-items: center; gap: 8px; }
.avatar {
    width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0;
    background: linear-gradient(150deg, var(--g100), var(--g200));
    color: var(--g900);
    display: inline-flex; align-items: center; justify-content: center;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.6);
}
.avatar .ico { width: 14px; height: 14px; }

/* ───────── Layout ───────── */
.wrap { max-width: 960px; width: 100%; margin: 0 auto; padding: 26px 20px 40px; flex: 1; }
.page-title { font-size: 1.6rem; font-weight: 900; letter-spacing: -0.5px; color: var(--g900); margin-bottom: 18px; }
.page-sub { font-weight: 600; font-size: 1rem; color: var(--text-light); }

.foot {
    border-top: 1px solid var(--border); background: var(--white);
    padding: 14px 20px; display: flex; justify-content: center; gap: 16px;
    font-size: 0.85rem; color: var(--text-light);
}
.foot a { color: var(--g700); text-decoration: none; }

/* ───────── Pestañas ───────── */
.tabs {
    display: flex; gap: 6px; margin-bottom: 18px; border-bottom: 2px solid var(--border);
    overflow-x: auto; scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tab {
    padding: 10px 18px 8px; text-decoration: none; color: var(--text-light);
    font-weight: 600; font-size: 0.95rem; border-bottom: 3px solid transparent;
    margin-bottom: -2px; border-radius: 8px 8px 0 0;
    display: inline-flex; align-items: center; gap: 7px;
    white-space: nowrap; flex-shrink: 0;
}
.tab .ico { width: 15px; height: 15px; opacity: 0.8; }
.tab.active .ico { opacity: 1; }
.tab:hover { background: var(--g50); color: var(--g800); }
.tab.active { color: var(--g800); border-bottom-color: var(--g600); }

/* ───────── Tarjetas ───────── */
.card {
    background: var(--white); border: 1px solid var(--border);
    border-radius: var(--radius); box-shadow: var(--shadow-sm);
    padding: 22px; margin-bottom: 18px;
}
.card h2 { font-size: 1.05rem; font-weight: 700; color: var(--g900); margin-bottom: 10px; }
.card-warn { border-left: 4px solid var(--warn); }
.card-head-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
.muted { color: var(--text-light); font-size: 0.9rem; margin-bottom: 12px; }
.note {
    margin-top: 14px; padding: 10px 14px; background: var(--g50);
    border-radius: 10px; font-size: 0.88rem; color: var(--text-light);
}
.note a { color: var(--g800); }
.empty {
    padding: 26px; text-align: center; color: var(--text-light);
    background: var(--bg-page); border: 1px dashed var(--border); border-radius: 10px;
}

/* ───────── Licencia ───────── */
.lic-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 16px; }
.lic-plan-label { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.6px; color: var(--text-light); }
.lic-plan { font-size: 1.55rem; font-weight: 900; letter-spacing: -0.5px; color: var(--g800); }

.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 12px; }
.kv { background: var(--bg-page); border: 1px solid var(--border); border-radius: 10px; padding: 10px 14px; }
.kv .k { display: block; font-size: 0.78rem; color: var(--text-light); margin-bottom: 2px; }
.kv .v { font-weight: 700; color: var(--text); }
.kv .v-warn { color: var(--warn); }

.feat-grid { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 8px; }
.feat { padding: 8px 12px; border-radius: 8px; font-size: 0.92rem; display: flex; gap: 8px; align-items: center; }
.feat-on  { background: var(--g50); color: var(--g900); }
.feat-off { background: #f3f4f3; color: #9aa79f; }
.feat-ico { display: inline-flex; align-items: center; }
.feat-ico .ico { width: 15px; height: 15px; stroke-width: 2.4; }
.feat-on .feat-ico { color: var(--g600); }

/* ───────── Tarjetas de servicios ───────── */
.svc-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 14px; margin-top: 6px; }
.svc-card {
    display: flex; flex-direction: column; gap: 10px;
    border: 1px solid var(--border); border-radius: 12px; padding: 16px;
    background: var(--white); box-shadow: var(--shadow-sm);
}
.svc-head { display: flex; align-items: flex-start; gap: 12px; }
.svc-head > div { flex: 1; min-width: 0; }
/* Tile degradado estilo ícono de app macOS */
.svc-ico {
    width: 46px; height: 46px; border-radius: 12px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    color: #fff;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.3), 0 5px 12px rgba(27,94,32,.22);
}
.svc-ico .ico { width: 24px; height: 24px; }
.svc-ico--pro    { background: linear-gradient(150deg, var(--g500) 0%, var(--g800) 100%); }
.svc-ico--bg     { background: linear-gradient(150deg, var(--g300) 0%, var(--g600) 100%); }
.svc-ico--caster {
    background: linear-gradient(150deg, #4c6ef5 0%, var(--navy) 100%);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.3), 0 5px 12px rgba(30,58,138,.22);
}
.svc-ico--tv {
    background: linear-gradient(150deg, #14b8a6 0%, #0f766e 100%);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.3), 0 5px 12px rgba(15,118,110,.22);
}
/* Tile suave para productos por descubrir (no contratados aún) */
.svc-ico--promo {
    background: linear-gradient(150deg, var(--g50), var(--g100));
    border: 1px solid var(--g100);
    color: var(--g700);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.7);
}
/* Upsell contextual dentro de la tarjeta del servicio */
.svc-upsell {
    display: block; text-decoration: none;
    padding: 8px 12px; border-radius: 10px; font-size: 0.84rem;
    background: linear-gradient(150deg, var(--g50), #fefff9);
    border: 1px dashed var(--g300); color: var(--g800);
}
.svc-upsell:hover { border-style: solid; background: var(--g50); }
.plan-list { list-style: none; display: flex; flex-direction: column; gap: 7px; margin: 0 0 14px; }
.plan-list li {
    padding: 9px 13px; border-radius: 10px; font-size: 0.9rem;
    background: var(--bg-page); border: 1px solid var(--border); color: var(--text-light);
}
.plan-list li strong { color: var(--g900); }

/* ───────── Catálogo del ecosistema (acordeones tipo disclosure macOS) ───────── */
.cat {
    border: 1px solid var(--border); border-radius: 14px;
    background: var(--white); margin-bottom: 10px; overflow: hidden;
}
.cat summary {
    display: flex; align-items: center; gap: 14px;
    padding: 14px 16px; cursor: pointer; list-style: none;
    transition: background 0.15s ease;
}
.cat summary::-webkit-details-marker { display: none; }
.cat summary:hover { background: var(--bg-page); }
.cat-title { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.cat-name { font-weight: 900; letter-spacing: -0.3px; color: var(--g900); font-size: 1.02rem; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cat-tag { font-size: 0.82rem; color: var(--text-light); }
.cat-chev {
    font-size: 1.5rem; color: var(--g400); font-weight: 700; line-height: 1;
    transition: transform 0.2s ease; flex-shrink: 0;
}
.cat[open] .cat-chev { transform: rotate(90deg); }
.cat-body { padding: 4px 18px 18px; border-top: 1px solid var(--border); }
.cat-body > p { font-size: 0.92rem; color: var(--text-light); margin: 12px 0; }
.cat-body > p strong { color: var(--g900); }
.cat-sub { margin: 14px 0; }
.cat-sub h4 {
    font-size: 0.92rem; font-weight: 800; color: var(--g800);
    margin-bottom: 8px; display: flex; align-items: center; gap: 8px;
}
.cat-list {
    list-style: none; display: grid;
    grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
    gap: 6px; margin: 10px 0;
}
.cat-list li {
    display: flex; align-items: flex-start; gap: 8px;
    font-size: 0.88rem; color: var(--text);
    padding: 7px 10px; background: var(--bg-page); border-radius: 8px;
}
.cat-list li .ico { width: 14px; height: 14px; margin-top: 3px; color: var(--g600); stroke-width: 2.4; }
.cat-list li strong { color: var(--g900); }
.cat-flow {
    font-size: 0.88rem; color: var(--g800); background: var(--g50);
    padding: 9px 13px; border-radius: 10px; margin: 12px 0;
}
.cat .svc-actions { margin-top: 14px; }
.svc-name { font-weight: 900; letter-spacing: -0.3px; color: var(--g900); font-size: 1.02rem; }
.svc-desc { font-size: 0.8rem; color: var(--text-light); margin-top: 2px; }
.svc-facts { list-style: none; display: flex; flex-direction: column; gap: 4px; }
.svc-facts li {
    display: flex; justify-content: space-between; gap: 8px; font-size: 0.88rem;
    background: var(--bg-page); border-radius: 8px; padding: 6px 10px;
}
.svc-facts li span { color: var(--text-light); }
.svc-pitch { font-size: 0.86rem; color: var(--text-light); flex: 1; }
.svc-pitch.v-warn { color: var(--warn); font-weight: 600; }
.svc-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.svc-note { font-size: 0.76rem; color: var(--text-light); }
.badge-neutral { background: #eef1ef; color: #6b7a70; }

/* ───────── Badges ───────── */
.badge {
    display: inline-flex; align-items: center; padding: 5px 12px; border-radius: 999px;
    font-size: 0.82rem; font-weight: 700; white-space: nowrap;
}
.badge-sm { padding: 2px 8px; font-size: 0.72rem; margin-left: 6px; }
.badge-ok   { background: var(--g50); color: var(--g800); }
.badge-err  { background: var(--danger-soft); color: var(--danger); }
.badge-soft { background: var(--g50); color: var(--g800); }

/* ───────── Equipos ───────── */
.dev-list { display: flex; flex-direction: column; gap: 10px; }
.dev {
    display: flex; align-items: center; gap: 14px;
    border: 1px solid var(--border); border-radius: 12px; padding: 12px 16px;
    background: var(--white);
}
.dev-ico {
    width: 42px; height: 42px; border-radius: 11px; flex-shrink: 0;
    background: linear-gradient(150deg, var(--g50), var(--g100));
    border: 1px solid var(--g100); color: var(--g800);
    display: flex; align-items: center; justify-content: center;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.7);
}
.dev-ico .ico { width: 21px; height: 21px; }
.dev-main { flex: 1; min-width: 0; }
.dev-name { font-weight: 700; color: var(--text); }
.dev-meta { font-size: 0.84rem; color: var(--text-light); margin-top: 2px; }
.dev-actions { flex-shrink: 0; }

/* ───────── Tabla sesiones ───────── */
.tbl { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.tbl th {
    text-align: left; padding: 8px 10px; color: var(--text-light);
    font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.5px;
    border-bottom: 2px solid var(--border);
}
.tbl td { padding: 10px; border-bottom: 1px solid var(--border); }
.td-right { text-align: right; }

/* ───────── Formularios ───────── */
.field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 12px; }
.field span { font-size: 0.85rem; font-weight: 600; color: var(--text-light); }
.field input, .field select, .field textarea {
    font-family: var(--font); font-size: 0.95rem; color: var(--text);
    padding: 10px 12px; border: 1px solid var(--border); border-radius: 10px;
    background: var(--white); outline: none; width: 100%;
}
.field input:focus, .field select:focus, .field textarea:focus {
    border-color: var(--g500); box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.15);
}
.field input:disabled { background: var(--bg-page); color: var(--text-light); }
.form-inline-col { max-width: 640px; }

/* ───────── Botones ───────── */
.btn .ico { width: 16px; height: 16px; }
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 7px;
    font-family: var(--font); font-weight: 700; font-size: 0.92rem;
    padding: 10px 20px; border-radius: 10px; border: 1px solid transparent;
    cursor: pointer; text-decoration: none; transition: all 0.15s ease;
}
.btn-sm { padding: 7px 14px; font-size: 0.84rem; }
.btn-block { width: 100%; }
.btn-primary { background: var(--g600); color: var(--white); box-shadow: 0 4px 14px rgba(76, 175, 80, 0.35); }
.btn-primary:hover { background: var(--g700); }
.btn-ghost { background: var(--white); color: var(--g800); border-color: var(--border); }
.btn-ghost:hover { background: var(--g50); }
.btn-danger { background: var(--white); color: var(--danger); border-color: #f2c9c5; }
.btn-danger:hover { background: var(--danger-soft); }
/* Botón WhatsApp Business (verde oficial de la marca WhatsApp) */
.btn-whatsapp { background: #25D366; color: #fff; box-shadow: 0 4px 14px rgba(37, 211, 102, 0.35); }
.btn-whatsapp:hover { background: #1EBE5A; }

/* ───────── Flash ───────── */
.flash { padding: 12px 16px; border-radius: 10px; margin-bottom: 14px; font-size: 0.92rem; font-weight: 600; }
.flash-ok  { background: var(--g50); color: var(--g900); border: 1px solid var(--g200); }
.flash-err { background: var(--danger-soft); color: var(--danger); border: 1px solid #f2c9c5; }

/* ───────── Login ───────── */
.login-body { background: linear-gradient(160deg, var(--g50) 0%, var(--bg-page) 45%, #ffffff 100%); }
.login-wrap { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 30px 16px; min-height: 100vh; }
.login-card {
    width: 100%; max-width: 400px; background: var(--white);
    border: 1px solid var(--border); border-radius: 18px; box-shadow: var(--shadow);
    padding: 34px 30px;
}
.login-title { text-align: center; font-size: 1.35rem; font-weight: 900; letter-spacing: -0.4px; color: var(--g900); margin: 6px 0 4px; }
.login-hint { text-align: center; color: var(--text-light); font-size: 0.9rem; margin-bottom: 18px; }
.login-foot { margin-top: 18px; text-align: center; font-size: 0.85rem; color: var(--text-light); }
.login-foot a { color: var(--g800); }
.login-back { margin-top: 16px; font-size: 0.88rem; }
.login-back a { color: var(--g800); text-decoration: none; }

/* ───────── Google Sign-In ───────── */
.login-divider {
    display: flex; align-items: center; gap: 12px;
    margin: 16px 0 14px; color: var(--text-light); font-size: 0.82rem;
}
.login-divider::before, .login-divider::after {
    content: ""; flex: 1; height: 1px; background: var(--border);
}
.gsi-center { display: flex; justify-content: center; }
.gsi-slot { min-height: 44px; }
.gsi-hint { margin-top: 10px; text-align: center; font-size: 0.78rem; color: var(--text-light); }

/* Aviso estructurado (ej. Google sin vincular) — informativo, estilo de la casa */
.notice {
    display: flex; gap: 12px; align-items: flex-start;
    background: var(--g50); border: 1px solid var(--g200);
    border-radius: 12px; padding: 14px 16px; margin-bottom: 14px;
    animation: tpq-rise 0.4s ease both;
}
.notice-ico {
    width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0;
    background: #fff; color: var(--g700); border: 1px solid var(--g200);
    display: inline-flex; align-items: center; justify-content: center;
}
.notice-ico .ico { width: 16px; height: 16px; }
.notice-body { min-width: 0; }
.notice-title { font-weight: 800; color: var(--g900); font-size: 0.92rem; margin-bottom: 4px; }
.notice-body p { font-size: 0.86rem; color: var(--text-light); margin: 0 0 6px; }
.notice-body p strong { color: var(--g900); }
.notice-link {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: 0.84rem; font-weight: 700; color: var(--g800); text-decoration: none;
    margin-top: 2px;
}
.notice-link:hover { text-decoration: underline; }
.notice-link .ico { color: #25D366; }

/* ───────── Responsive ───────── */
@media (max-width: 560px) {
    .dev { flex-wrap: wrap; }
    .dev-actions { width: 100%; display: flex; justify-content: flex-end; }
    .topbar-inner { flex-wrap: wrap; }
    .tbl th:nth-child(3), .tbl td:nth-child(3) { display: none; } /* IP en móvil */
}

/* ══════════════════════════════════════════════════════════════════
   PULIDO v2 — profundidad, cristal y microinteracciones
   Animaciones minimalistas (300-600ms, curvas suaves), sin JS.
   ══════════════════════════════════════════════════════════════════ */

/* Fondo con malla de luz suave (nada de plano) */
body {
    background:
        radial-gradient(1100px 560px at 88% -12%, rgba(76, 175, 80, 0.10), transparent 62%),
        radial-gradient(900px 520px at -12% 34%, rgba(129, 199, 132, 0.12), transparent 58%),
        radial-gradient(700px 420px at 55% 115%, rgba(200, 230, 201, 0.20), transparent 60%),
        var(--bg-page);
    background-attachment: fixed;
}

/* Barra superior de cristal, siempre visible */
.topbar {
    position: sticky; top: 0; z-index: 60;
    background: rgba(255, 255, 255, 0.78);
    -webkit-backdrop-filter: blur(16px) saturate(170%);
    backdrop-filter: blur(16px) saturate(170%);
    border-bottom: 1px solid rgba(226, 239, 230, 0.9);
}

/* Entradas escalonadas al cargar */
@keyframes tpq-rise {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: none; }
}
.wrap > * { animation: tpq-rise 0.55s cubic-bezier(0.21, 0.86, 0.36, 1) both; }
.wrap > *:nth-child(2) { animation-delay: 0.05s; }
.wrap > *:nth-child(3) { animation-delay: 0.10s; }
.wrap > *:nth-child(4) { animation-delay: 0.16s; }
.wrap > *:nth-child(5) { animation-delay: 0.24s; }
.wrap > *:nth-child(6) { animation-delay: 0.32s; }
.svc-grid .svc-card:nth-child(1) { animation: tpq-rise 0.5s 0.10s cubic-bezier(0.21,0.86,0.36,1) both; }
.svc-grid .svc-card:nth-child(2) { animation: tpq-rise 0.5s 0.18s cubic-bezier(0.21,0.86,0.36,1) both; }
.svc-grid .svc-card:nth-child(3) { animation: tpq-rise 0.5s 0.26s cubic-bezier(0.21,0.86,0.36,1) both; }
.cat:nth-of-type(1) { animation: tpq-rise 0.5s 0.12s cubic-bezier(0.21,0.86,0.36,1) both; }
.cat:nth-of-type(2) { animation: tpq-rise 0.5s 0.18s cubic-bezier(0.21,0.86,0.36,1) both; }
.cat:nth-of-type(3) { animation: tpq-rise 0.5s 0.24s cubic-bezier(0.21,0.86,0.36,1) both; }
.cat:nth-of-type(4) { animation: tpq-rise 0.5s 0.30s cubic-bezier(0.21,0.86,0.36,1) both; }
.cat:nth-of-type(5) { animation: tpq-rise 0.5s 0.36s cubic-bezier(0.21,0.86,0.36,1) both; }
.flash { animation: tpq-rise 0.4s ease both; }

/* Título con acento de marca */
.page-title { position: relative; padding-bottom: 10px; }
.page-title::after {
    content: ""; position: absolute; left: 0; bottom: 0;
    width: 58px; height: 4px; border-radius: 4px;
    background: linear-gradient(90deg, var(--g500), var(--g300));
}

/* Pestañas: subrayado que se desliza */
.tab { border-bottom-color: transparent; position: relative; transition: color 0.2s ease, background 0.2s ease; }
.tab.active { border-bottom-color: transparent; }
.tab::after {
    content: ""; position: absolute; left: 14px; right: 14px; bottom: -2px;
    height: 3px; border-radius: 3px;
    background: linear-gradient(90deg, var(--g500), var(--g700));
    transform: scaleX(0); transform-origin: left;
    transition: transform 0.28s cubic-bezier(0.22, 0.9, 0.35, 1);
}
.tab:hover::after { transform: scaleX(0.35); }
.tab.active::after { transform: scaleX(1); }

/* Tarjetas con capas de sombra reales */
.card {
    box-shadow: 0 1px 2px rgba(27, 94, 32, 0.05), 0 10px 28px rgba(27, 94, 32, 0.07);
}
.kv { transition: border-color 0.2s ease, background 0.2s ease; }
.kv:hover { border-color: var(--g200); background: #fbfefb; }

/* Tarjetas de servicio: hairline superior + elevación al pasar */
.svc-card { position: relative; overflow: hidden; transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease; }
.svc-card::before {
    content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px;
    background: linear-gradient(90deg, var(--g400), var(--g700));
}
.svc-card:has(.svc-ico--caster)::before { background: linear-gradient(90deg, #4c6ef5, var(--navy)); }
.svc-card:has(.svc-ico--tv)::before { background: linear-gradient(90deg, #14b8a6, #0f766e); }
.svc-card:has(.svc-ico--promo)::before { background: linear-gradient(90deg, var(--g200), var(--g400)); }
.svc-card:hover { transform: translateY(-3px); box-shadow: 0 16px 32px rgba(27, 94, 32, 0.13); border-color: var(--g200); }
.svc-ico { transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); }
.svc-card:hover .svc-ico { transform: scale(1.07) rotate(-3deg); }

/* Botones: prensado físico y halo */
.btn { transition: transform 0.16s ease, box-shadow 0.22s ease, background 0.2s ease, border-color 0.2s ease; }
.btn:hover  { transform: translateY(-1px); }
.btn:active { transform: translateY(0) scale(0.97); }
.btn-primary:hover  { box-shadow: 0 7px 20px rgba(76, 175, 80, 0.45); }
.btn-whatsapp:hover { box-shadow: 0 7px 20px rgba(37, 211, 102, 0.45); }

/* Estado "Activo" que respira */
@keyframes tpq-breathe {
    0%, 100% { box-shadow: 0 0 0 0 rgba(76, 175, 80, 0); }
    50%      { box-shadow: 0 0 0 5px rgba(76, 175, 80, 0.14); }
}
.badge-ok { animation: tpq-breathe 2.8s ease-in-out infinite; }

/* Acordeones del catálogo: apertura suave y foco */
.cat { transition: box-shadow 0.25s ease, border-color 0.25s ease; }
.cat:hover { border-color: var(--g200); }
.cat[open] { box-shadow: 0 12px 28px rgba(27, 94, 32, 0.10); border-color: var(--g200); }
@keyframes tpq-cat-in {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: none; }
}
.cat[open] .cat-body { animation: tpq-cat-in 0.32s ease both; }
.cat summary .svc-ico { transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); }
.cat summary:hover .svc-ico { transform: scale(1.07) rotate(-3deg); }
.cat summary:focus-visible { outline: 3px solid rgba(76, 175, 80, 0.35); outline-offset: -3px; border-radius: 14px; }
.cat-list li { transition: background 0.18s ease, transform 0.18s ease; }
.cat-list li:hover { background: var(--g50); transform: translateX(3px); }
.svc-upsell { transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease; }
.svc-upsell:hover { transform: translateX(3px); }

/* Medidores de uso (equipos, tokens, días) */
.meter { height: 6px; border-radius: 99px; background: var(--g100); overflow: hidden; margin-top: 2px; }
.meter-sm { height: 4px; margin-top: 8px; }
@keyframes tpq-meter { from { transform: scaleX(0); } }
.meter > span {
    display: block; height: 100%; border-radius: 99px;
    background: linear-gradient(90deg, var(--g400), var(--g600));
    transform-origin: left;
    animation: tpq-meter 0.9s 0.25s cubic-bezier(0.22, 0.9, 0.35, 1) both;
}

/* Equipos y sesiones */
.dev { transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease; }
.dev:hover { transform: translateY(-2px); box-shadow: 0 12px 24px rgba(27, 94, 32, 0.10); border-color: var(--g200); }
.dev-ico { transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); }
.dev:hover .dev-ico { transform: scale(1.06); }
.feat { transition: transform 0.18s ease; }
.feat-on:hover { transform: translateY(-1px); }

/* Topbar y login */
.avatar { transition: transform 0.25s ease; }
.hello:hover .avatar { transform: scale(1.1); }
.login-card {
    animation: tpq-rise 0.6s cubic-bezier(0.21, 0.86, 0.36, 1) both;
    box-shadow: 0 1px 2px rgba(27, 94, 32, 0.06), 0 20px 48px rgba(27, 94, 32, 0.13);
}
.login-back { animation: tpq-rise 0.6s 0.15s cubic-bezier(0.21, 0.86, 0.36, 1) both; }
.field input, .field select, .field textarea { transition: border-color 0.2s ease, box-shadow 0.2s ease; }

/* ── Fix layout tarjetas de servicio: el badge de estado vive en su propia
      fila (jamás pelea con el título) y máx. 2 columnas con aire ── */
.wrap { max-width: 1020px; }
.svc-grid { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 16px; }
.svc-head { align-items: center; }
.svc-name { font-size: 1.08rem; }
.svc-status { display: flex; }
.svc-status .badge { font-size: 0.8rem; }

/* Accesibilidad: sin animaciones si el usuario lo pide */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .topbar { position: static; }
}
