/* ================================================================
   base.css — Bloggent Shared Styles
   Covers: CSS variables, reset, body, layout, forms, buttons,
           messages, hero, avatar, profile, status boxes, payment
================================================================ */

/* ---------------- CSS Variables ---------------- */
:root {
    --indigo: #6366f1;
    --violet: #8b5cf6;
    --cyan: #22d3ee;
    --ink: #e7ebf7;
    --muted: #93a0bd;
    --line: rgba(255, 255, 255, 0.12);
    --glass: rgba(255, 255, 255, 0.055);
    --field-bg: rgba(255, 255, 255, 0.04);
    --radius: 13px;
}

* { box-sizing: border-box; }

/* ---------------- Body & Background ---------------- */
body {
    margin: 0;
    font-family: 'Sora', 'Hind Siliguri', system-ui, sans-serif;
    color: var(--ink);
    background:
        radial-gradient(900px 600px at 85% -10%, rgba(99, 102, 241, 0.28), transparent 60%),
        radial-gradient(800px 600px at 10% 110%, rgba(34, 211, 238, 0.20), transparent 60%),
        linear-gradient(160deg, #080b1a 0%, #0b1024 50%, #070a18 100%);
    background-attachment: fixed;
    min-height: 100vh;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* ---------------- Background Canvas & Overlay ---------------- */
.bg-canvas {
    position: fixed; inset: 0; width: 100%; height: 100%;
    z-index: -2; display: block;
}
.bg-overlay {
    position: fixed; inset: 0; z-index: -1; pointer-events: none;
    background: radial-gradient(1100px 700px at 50% 30%, transparent 0%, rgba(7, 10, 24, 0.55) 80%);
}

/* ---------------- Preloader ---------------- */
.preloader {
    position: fixed; inset: 0; z-index: 9999;
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px;
    background: #070a18;
    transition: opacity .7s ease, visibility .7s ease;
}
.preloader.hidden { opacity: 0; visibility: hidden; }
.loader-ring {
    width: 58px; height: 58px; border-radius: 50%;
    border: 3px solid rgba(255, 255, 255, 0.12);
    border-top-color: var(--cyan);
    border-right-color: var(--indigo);
    animation: spin 0.9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loader-brand {
    font-weight: 800; letter-spacing: 0.35em; font-size: 1.1rem;
    background: linear-gradient(90deg, var(--indigo), var(--cyan));
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.loader-text { color: var(--muted); font-size: 0.85rem; letter-spacing: .1em; }
.loader-text span { animation: blink 1.2s infinite; }
.loader-text span:nth-child(2) { animation-delay: .2s; }
.loader-text span:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 0%, 100% { opacity: .2; } 50% { opacity: 1; } }

/* ---------------- Layout ---------------- */
.page {
    position: relative; z-index: 1;
    min-height: 100vh;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    padding: 40px 16px;
}

/* Coming-soon headline */
.coming-soon { text-align: center; max-width: 620px; margin-bottom: 26px; }
.cs-badge {
    display: inline-block; padding: 6px 14px; border-radius: 999px;
    font-size: 0.74rem; font-weight: 600; letter-spacing: 0.22em; color: #c7d2fe;
    background: rgba(99, 102, 241, 0.16); border: 1px solid rgba(99, 102, 241, 0.4);
    margin-bottom: 18px;
}
.cs-title { margin: 0 0 14px; font-size: 2.9rem; font-weight: 800; line-height: 1.1; letter-spacing: -0.02em; }
.cs-title .grad {
    background: linear-gradient(100deg, var(--indigo) 0%, var(--violet) 45%, var(--cyan) 100%);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.cs-sub { margin: 0; color: var(--muted); font-size: 1.02rem; }

/* Glass card */
.card {
    position: relative; z-index: 1;
    width: 100%; max-width: 560px;
    background: var(--glass);
    border: 1px solid var(--line);
    border-radius: 22px;
    overflow: hidden;
    backdrop-filter: blur(18px) saturate(140%);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.45);
}
.card-body { padding: 26px 30px 30px; }

.form-head { text-align: center; margin-bottom: 20px; }
.form-head h2 { margin: 0 0 4px; font-size: 1.4rem; font-weight: 700; }
.form-head p { margin: 0; color: var(--muted); font-size: 0.94rem; }

/* Hero section (otp / profile) */
.hero {
    position: relative; padding: 32px 28px 26px; text-align: center;
    background: linear-gradient(135deg, rgba(99,102,241,.5), rgba(139,92,246,.42) 55%, rgba(34,211,238,.4));
    border-bottom: 1px solid var(--line);
}
.hero.hero-success {
    background: linear-gradient(135deg, rgba(16,185,129,.5), rgba(5,150,105,.42) 60%, rgba(34,211,238,.38));
}
.hero-logo {
    width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 18px;
    background: rgba(255, 255, 255, 0.16); border: 1px solid rgba(255, 255, 255, 0.3);
    display: grid; place-items: center;
}
.hero-logo svg { width: 31px; height: 31px; color: #fff; }
.hero h1 { margin: 0 0 5px; font-size: 1.5rem; font-weight: 700; color: #fff; }
.hero p { margin: 0; color: rgba(255, 255, 255, 0.9); font-size: 0.97rem; }
.hero strong { color: #fff; }
.avatar {
    width: 76px; height: 76px; margin: 0 auto 12px; border-radius: 50%;
    background: rgba(255, 255, 255, 0.18); border: 2px solid rgba(255, 255, 255, 0.45);
    display: grid; place-items: center; font-size: 2rem; font-weight: 700; color: #fff;
}
.verified-badge {
    display: inline-block; margin-top: 10px; padding: 4px 12px; border-radius: 999px;
    font-size: 0.8rem; font-weight: 600; color: #fff;
    background: rgba(255, 255, 255, 0.2); border: 1px solid rgba(255, 255, 255, 0.35);
}

/* ---------------- Forms ---------------- */
.reg-form { display: flex; flex-direction: column; gap: 15px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field-row { display: flex; gap: 14px; }
.field-row .field { flex: 1; min-width: 0; }
.field label { font-weight: 600; font-size: 0.9rem; color: #c4cce0; }
.req { color: #fb7185; }

.section-label {
    display: flex; align-items: center; gap: 12px; margin: 12px 0 2px;
    font-size: 0.78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
    color: var(--cyan);
}
.section-label::after { content: ""; flex: 1; height: 1px; background: linear-gradient(to right, var(--line), transparent); }

.input-group { position: relative; display: flex; align-items: center; }
.input-group.ig-top { align-items: flex-start; }
.ig-icon { position: absolute; left: 14px; width: 18px; height: 18px; color: #8591b3; pointer-events: none; transition: color .15s; }
.input-group.ig-top .ig-icon { top: 14px; }
.input-group:focus-within .ig-icon { color: var(--cyan); }

.form-input, .form-select {
    width: 100%; padding: 12px 14px 12px 42px;
    border: 1.5px solid var(--line); border-radius: var(--radius);
    font-family: inherit; font-size: 1rem; color: var(--ink);
    background: var(--field-bg);
    transition: border-color .15s, box-shadow .15s, background .15s;
}
textarea.form-input { resize: vertical; min-height: 92px; padding-top: 12px; }
.form-input::placeholder { color: #6b769a; }
.form-input:focus, .form-select:focus {
    outline: none; border-color: var(--indigo); background: rgba(255, 255, 255, 0.06);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.22);
}
.form-select {
    appearance: none; -webkit-appearance: none; padding-right: 40px; cursor: pointer;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%238591b3' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 14px center;
}
.form-select option { color: #111; }

.ig-suffix {
    position: absolute; right: 10px; font-size: 0.8rem; font-weight: 600; color: #c4cce0;
    background: rgba(255, 255, 255, 0.08); padding: 4px 9px; border-radius: 8px; pointer-events: none;
}
.input-group.has-suffix .form-input { padding-right: 72px; }

.hint { margin: 0; font-size: 0.8rem; color: var(--muted); }
.err { margin: 0; font-size: 0.84rem; color: #fb7185; font-weight: 500; }

/* Checkbox */
.check-row {
    display: flex; align-items: center; gap: 10px; cursor: pointer;
    font-weight: 500; color: #c4cce0; font-size: 0.94rem;
    background: var(--field-bg); border: 1.5px solid var(--line);
    border-radius: var(--radius); padding: 12px 14px;
}
.check-row:hover { background: rgba(255, 255, 255, 0.06); }
.check-row input[type="checkbox"], .form-check {
    width: 18px; height: 18px; accent-color: var(--indigo); cursor: pointer; flex-shrink: 0;
}

/* ---------------- Buttons ---------------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 9px;
    width: 100%; padding: 13px 18px; border: none; border-radius: var(--radius);
    font-family: inherit; font-size: 1.02rem; font-weight: 600; cursor: pointer;
    text-decoration: none; transition: transform .05s, box-shadow .15s, opacity .15s; margin-top: 6px;
}
.btn svg { width: 18px; height: 18px; }
.btn-primary {
    background: linear-gradient(100deg, var(--indigo), var(--violet) 55%, #4f46e5);
    color: #fff; box-shadow: 0 12px 26px rgba(99, 102, 241, 0.4);
}
.btn-primary:hover { box-shadow: 0 14px 32px rgba(99, 102, 241, 0.55); transform: translateY(-1px); }
.btn-primary:active { transform: translateY(1px); }
.btn-ghost { background: rgba(255, 255, 255, 0.05); color: #c7d2fe; border: 1.5px solid var(--line); }
.btn-ghost:hover { background: rgba(255, 255, 255, 0.1); }
.btn-danger { background: linear-gradient(100deg, #ef4444, #dc2626); color: #fff; box-shadow: 0 12px 26px rgba(239, 68, 68, 0.35); }
.btn-danger:hover { box-shadow: 0 14px 32px rgba(239, 68, 68, 0.5); transform: translateY(-1px); }
.btn-danger:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; box-shadow: none; transform: none; }

.secure-note {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    margin: 16px 0 0; color: var(--muted); font-size: 0.84rem; text-align: center;
}
.secure-note svg { width: 15px; height: 15px; flex-shrink: 0; }

/* ---------------- Messages ---------------- */
.messages { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
.msg { padding: 12px 14px; border-radius: 12px; font-size: 0.92rem; font-weight: 500; border: 1px solid transparent; }
.msg.success { background: rgba(16, 185, 129, 0.14); color: #6ee7b7; border-color: rgba(16, 185, 129, 0.4); }
.msg.error   { background: rgba(239, 68, 68, 0.14); color: #fca5a5; border-color: rgba(239, 68, 68, 0.4); }
.msg.warning { background: rgba(245, 158, 11, 0.14); color: #fcd34d; border-color: rgba(245, 158, 11, 0.4); }
.msg.info    { background: rgba(99, 102, 241, 0.14); color: #c7d2fe; border-color: rgba(99, 102, 241, 0.4); }

/* ---------------- Profile / ID Box / Detail List ---------------- */
.id-box {
    background: rgba(99, 102, 241, 0.12); border: 1.5px dashed rgba(99, 102, 241, 0.5);
    border-radius: var(--radius); padding: 16px; margin: 4px 0 18px;
    display: flex; flex-direction: column; gap: 6px; text-align: center;
}
.id-label { font-size: 0.82rem; color: #c7d2fe; font-weight: 600; letter-spacing: .05em; }
.id-value { font-size: 1.5rem; font-weight: 700; letter-spacing: 1px; color: #fff; word-break: break-all; }
.detail-list { display: flex; flex-direction: column; margin: 0 0 6px; }
.detail-row {
    display: flex; justify-content: space-between; gap: 12px; padding: 11px 2px;
    border-bottom: 1px solid var(--line); font-size: 0.95rem;
}
.detail-row:last-child { border-bottom: none; }
.detail-row span { color: var(--muted); }
.detail-row strong { color: var(--ink); text-align: right; word-break: break-word; font-weight: 600; }

.brand-footer { margin-top: 22px; color: #677196; font-size: 0.84rem; letter-spacing: .5px; }

/* ---------------- Status Boxes ---------------- */
.hero-pending   { background: linear-gradient(135deg, rgba(245,158,11,.5), rgba(234,179,8,.42) 60%, rgba(99,102,241,.4)); }
.hero-approved  { background: linear-gradient(135deg, rgba(16,185,129,.5), rgba(5,150,105,.42) 60%, rgba(34,211,238,.38)); }
.hero-rejected  { background: linear-gradient(135deg, rgba(239,68,68,.5), rgba(220,38,38,.42) 60%, rgba(139,92,246,.35)); }
.hero-cancelled { background: linear-gradient(135deg, rgba(100,116,139,.5), rgba(71,85,105,.45) 60%, rgba(30,41,59,.4)); }

.status-pill {
    display: inline-block; margin-top: 10px; padding: 5px 14px; border-radius: 999px;
    font-size: 0.8rem; font-weight: 700; color: #fff; letter-spacing: .03em;
    background: rgba(255, 255, 255, 0.2); border: 1px solid rgba(255, 255, 255, 0.4);
}

.status-box { border-radius: var(--radius); padding: 14px 16px; margin-bottom: 18px; border: 1px solid transparent; }
.status-box strong { display: block; margin-bottom: 4px; font-size: 1rem; }
.status-box p { margin: 0; font-size: 0.92rem; color: var(--muted); }
.status-box.status-pending   { background: rgba(245,158,11,.12); border-color: rgba(245,158,11,.4); }
.status-box.status-pending strong   { color: #fcd34d; }
.status-box.status-approved  { background: rgba(16,185,129,.12); border-color: rgba(16,185,129,.4); }
.status-box.status-approved strong  { color: #6ee7b7; }
.status-box.status-rejected  { background: rgba(239,68,68,.12); border-color: rgba(239,68,68,.4); }
.status-box.status-rejected strong  { color: #fca5a5; }
.status-box.status-cancelled { background: rgba(100,116,139,.14); border-color: rgba(100,116,139,.4); }
.status-box.status-cancelled strong { color: #cbd5e1; }

/* Payment box */
.payment-box {
    border-radius: var(--radius); padding: 14px 16px; margin-bottom: 18px;
    background: rgba(99, 102, 241, 0.12); border: 1px solid rgba(99, 102, 241, 0.4);
}
.payment-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.payment-head > span:first-child { font-weight: 700; color: #c7d2fe; }
.payment-box p { margin: 0; font-size: 0.92rem; color: var(--ink); }
.pay-pill { padding: 4px 12px; border-radius: 999px; font-size: 0.8rem; font-weight: 700; }
.pay-pill.pending { background: rgba(245,158,11,.16); color: #fcd34d; border: 1px solid rgba(245,158,11,.45); }
.pay-pill.paid { background: rgba(16,185,129,.16); color: #6ee7b7; border: 1px solid rgba(16,185,129,.45); }

/* ---------------- Responsive Utilities ---------------- */
@media (max-width: 560px) {
    .cs-title { font-size: 2.1rem; }
    .card-body { padding: 22px 18px 26px; }
    .field-row { flex-direction: column; gap: 15px; }
}
