/* ACBIZ CORE v1 - Base Stylesheet */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --primary:   #1a56db;
    --primary-h: #1648c0;
    --dark:      #111827;
    --gray:      #6b7280;
    --light:     #f9fafb;
    --border:    #e5e7eb;
    --radius:    8px;
    --shadow:    0 1px 3px rgba(0,0,0,0.1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--light);
    color: var(--dark);
    line-height: 1.6;
    font-size: 16px;
}

.container { max-width: 1100px; margin: 0 auto; padding: 0 20px; }

/* Navbar */
.navbar {
    background: #fff;
    border-bottom: 1px solid var(--border);
    padding: 14px 0;
    position: sticky; top: 0; z-index: 100;
    box-shadow: var(--shadow);
}
.navbar .container { display: flex; align-items: center; justify-content: space-between; }
.brand { font-size: 20px; font-weight: 700; color: var(--primary); text-decoration: none; letter-spacing: -0.5px; }
.nav-links { display: flex; gap: 20px; }
.nav-links a { color: var(--gray); text-decoration: none; font-size: 14px; font-weight: 500; transition: color .2s; }
.nav-links a:hover { color: var(--primary); }

/* Main */
main.container { padding-top: 40px; padding-bottom: 60px; min-height: calc(100vh - 130px); }

/* Hero */
.hero { text-align: center; padding: 60px 20px; }
.hero h1 { font-size: 42px; font-weight: 800; margin-bottom: 16px; }
.hero p  { font-size: 18px; color: var(--gray); margin-bottom: 32px; }
.btn-group { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* Features */
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; margin-top: 60px; }
.feature-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.feature-card h3 { font-size: 18px; margin-bottom: 8px; }
.feature-card p  { color: var(--gray); font-size: 14px; }

/* Buttons */
.btn { display: inline-block; padding: 10px 24px; border-radius: var(--radius); font-size: 15px; font-weight: 600; cursor: pointer; border: none; text-decoration: none; transition: background .2s, transform .1s; }
.btn:active { transform: scale(.98); }
.btn-primary  { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-h); }
.btn-outline  { background: transparent; color: var(--primary); border: 2px solid var(--primary); }
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-full { width: 100%; text-align: center; }

/* Auth Card */
.auth-card { max-width: 420px; margin: 40px auto; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 36px; box-shadow: var(--shadow); }
.auth-card h2 { font-size: 24px; margin-bottom: 28px; }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; color: var(--dark); }
.form-group input { width: 100%; padding: 10px 14px; border: 1px solid var(--border); border-radius: var(--radius); font-size: 15px; transition: border-color .2s; }
.form-group input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(26,86,219,.12); }
.auth-footer { margin-top: 20px; text-align: center; font-size: 14px; color: var(--gray); }
.auth-footer a { color: var(--primary); font-weight: 600; }

/* Footer */
.footer { background: #fff; border-top: 1px solid var(--border); padding: 20px 0; text-align: center; font-size: 13px; color: var(--gray); }

/* ── Payment / Lenco Styles ─────────────────────────────────── */
.pay-wrap { display: grid; grid-template-columns: 1fr 300px; gap: 30px; align-items: start; max-width: 900px; margin: 0 auto; }
@media (max-width: 700px) { .pay-wrap { grid-template-columns: 1fr; } }

.pay-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow); }
.pay-card h2 { font-size: 22px; margin-bottom: 4px; }
.pay-sub { color: var(--gray); font-size: 14px; margin-bottom: 28px; }
.pay-secure { text-align: center; font-size: 12px; color: var(--gray); margin-top: 16px; }

.input-prefix { display: flex; align-items: center; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.input-prefix .prefix { background: #f3f4f6; padding: 10px 12px; font-size: 14px; font-weight: 600; color: var(--gray); border-right: 1px solid var(--border); white-space: nowrap; }
.input-prefix input { border: none; border-radius: 0; flex: 1; }
.input-prefix input:focus { box-shadow: none; border-color: transparent; }

.channel-select { display: flex; gap: 16px; }
.channel-opt { display: flex; align-items: center; gap: 6px; font-size: 14px; cursor: pointer; padding: 8px 14px; border: 1px solid var(--border); border-radius: var(--radius); background: #f9fafb; }
.channel-opt input { margin: 0; }

.pay-sidebar { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.pay-sidebar h4 { font-size: 15px; margin-bottom: 14px; }

.sandbox-note { background: #fff8e1; border: 1px solid #ffe082; border-radius: 6px; padding: 12px; font-size: 13px; color: #5d4037; margin-top: 16px; }
.sandbox-note code { background: #fff3cd; padding: 2px 6px; border-radius: 4px; font-size: 12px; }

.alert { padding: 12px 16px; border-radius: var(--radius); font-size: 14px; margin-bottom: 16px; }
.alert-error { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }

/* Table */
.page-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.page-header h2 { font-size: 22px; }
.table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.data-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.data-table th { background: #f9fafb; padding: 12px 16px; text-align: left; font-weight: 600; font-size: 13px; color: var(--gray); border-bottom: 1px solid var(--border); }
.data-table td { padding: 12px 16px; border-bottom: 1px solid #f3f4f6; }
.data-table tr:last-child td { border-bottom: none; }
.data-table code { background: #f3f4f6; padding: 2px 6px; border-radius: 4px; font-size: 12px; }

/* Badges */
.badge { display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 12px; font-weight: 600; }
.badge-successful { background: #d1fae5; color: #065f46; }
.badge-pending    { background: #fef3c7; color: #92400e; }
.badge-failed     { background: #fee2e2; color: #991b1b; }

/* Empty state */
.empty-state { text-align: center; padding: 60px 20px; color: var(--gray); }
.empty-state p { font-size: 18px; margin-bottom: 20px; }

/* ── Currency Pills ─────────────────────────────────────── */
.currency-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 8px;
}

.pill {
    padding: 6px 14px;
    border-radius: 20px;
    border: 1.5px solid var(--border);
    background: #f9fafb;
    font-size: 13px;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: all .15s;
    line-height: 1.4;
}

.pill:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: #eff6ff;
}

.pill.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* ── Amount Preview ─────────────────────────────────────── */
.amount-display {
    background: linear-gradient(135deg, #1a56db, #1e40af);
    color: #fff;
    text-align: center;
    padding: 14px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

/* ── Currency Sidebar Badge ─────────────────────────────── */
.currency-info { margin-top: 16px; }

.currency-info h5 {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--gray);
    margin-bottom: 8px;
}

.currency-badge {
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    color: #1e40af;
    padding: 8px 12px;
    border-radius: var(--radius);
    font-size: 13px;
    font-weight: 600;
}

/* ── Amount Input Row ───────────────────────────────────── */
.amount-input-row {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.amount-input-row input {
    flex: 1;
}

.selected-currency-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: #f9fafb;
    cursor: pointer;
    font-size: 14px;
    font-weight: 700;
    color: #0f172a;
    white-space: nowrap;
    user-select: none;
    transition: border-color .2s, background .2s;
}

.selected-currency-pill:hover {
    border-color: var(--primary);
    background: #eff6ff;
}

.pill-arrow {
    font-size: 10px;
    color: #94a3b8;
}

/* ── Currency Panel ─────────────────────────────────────── */
.currency-panel {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: 0 8px 24px rgba(0,0,0,.12);
    margin-bottom: 16px;
    overflow: hidden;
}

.currency-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: #f8fafc;
    border-bottom: 1px solid var(--border);
    font-size: 13px;
    font-weight: 700;
    color: #475569;
}

.panel-close {
    background: none;
    border: none;
    font-size: 16px;
    cursor: pointer;
    color: #94a3b8;
    padding: 0 4px;
}

.panel-close:hover { color: #dc2626; }

.currency-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 14px;
}

.cpill {
    padding: 6px 12px;
    border-radius: 20px;
    border: 1.5px solid var(--border);
    background: #f9fafb;
    font-size: 13px;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: all .15s;
}

.cpill:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: #eff6ff;
}

.cpill.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* ── Conversion Box (under amount) ─────────────────────── */
.conversion-box {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: var(--radius);
    padding: 12px 16px;
    margin-bottom: 16px;
}

.conv-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.conv-item { flex: 1; }

.conv-label {
    font-size: 11px;
    color: #16a34a;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .4px;
    margin-bottom: 2px;
}

.conv-value {
    font-size: 16px;
    font-weight: 700;
    color: #14532d;
}

.conv-arrow {
    font-size: 20px;
    color: #16a34a;
}

.conv-rate {
    font-size: 11px;
    color: #4ade80;
    margin-top: 6px;
    text-align: center;
}

/* ── Amount Preview ─────────────────────────────────────── */
.amount-display {
    background: linear-gradient(135deg, #1a56db, #1e40af);
    color: #fff;
    text-align: center;
    padding: 14px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

/* ── Sidebar Converter Widget ───────────────────────────── */
.converter-widget {
    background: #f8fafc;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    margin-top: 12px;
}

.conv-input-row {
    display: flex;
    gap: 6px;
}

.conv-input-row input {
    flex: 1;
    min-width: 0;
}

.conv-select {
    width: 110px;
    padding: 8px 6px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 13px;
    background: #fff;
    cursor: pointer;
    flex-shrink: 0;
}

.swap-row {
    display: flex;
    justify-content: center;
    margin: 6px 0;
}

.swap-btn {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 50%;
    width: 32px;
    height: 32px;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s, transform .2s;
}

.swap-btn:hover {
    background: var(--primary);
    color: #fff;
    transform: rotate(180deg);
}

.conv-rate-display {
    font-size: 13px;
    font-weight: 600;
    color: var(--primary);
    text-align: center;
    margin-top: 10px;
    padding: 8px;
    background: #eff6ff;
    border-radius: var(--radius);
    min-height: 34px;
}

.conv-last-updated {
    font-size: 11px;
    color: #94a3b8;
    text-align: center;
    margin-top: 6px;
}


/* ═══════════════════════════════════════════════════════════
   ZRA Smart Invoice Styles
   ═══════════════════════════════════════════════════════════ */

/* ── Page Header ─────────────────────────────────────────── */
.zra-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
    flex-wrap: wrap;
    gap: 16px;
}

.zra-header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.zra-logo-wrap {
    width: 56px; height: 56px;
    background: linear-gradient(135deg, #16a34a, #15803d);
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 26px;
    box-shadow: 0 4px 12px rgba(22,163,74,.25);
    flex-shrink: 0;
}

.zra-title {
    font-size: 26px;
    font-weight: 800;
    color: var(--dark);
    margin: 0 0 2px;
    letter-spacing: -.5px;
}

.zra-subtitle {
    font-size: 13px;
    color: var(--gray);
    margin: 0;
}

/* ── Environment Badge ───────────────────────────────────── */
.zra-env-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
}

.zra-env-sandbox {
    background: #fff8e1;
    color: #92400e;
    border: 1px solid #fde68a;
}

.zra-env-production {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
}

/* ── Status Card ─────────────────────────────────────────── */
.zra-status-card {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 20px 24px;
    border-radius: var(--radius);
    border: 1px solid;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.zra-status-ok {
    background: #f0fdf4;
    border-color: #86efac;
}

.zra-status-warn {
    background: #fffbeb;
    border-color: #fcd34d;
}

.zra-status-icon {
    font-size: 24px;
    flex-shrink: 0;
    line-height: 1.4;
}

.zra-status-body {
    flex: 1;
    min-width: 0;
}

.zra-status-body strong {
    font-size: 15px;
    display: block;
    margin-bottom: 4px;
}

.zra-status-body p {
    font-size: 14px;
    color: var(--gray);
    margin: 0;
}

.zra-status-body code {
    background: rgba(0,0,0,.06);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
    font-family: monospace;
}

/* ── Info Cards ──────────────────────────────────────────── */
.zra-grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
}

.zra-info-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px 20px;
    box-shadow: var(--shadow);
}

.zra-info-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .6px;
    color: var(--gray);
    margin-bottom: 6px;
}

.zra-info-value {
    font-size: 15px;
    font-weight: 700;
    color: var(--dark);
    font-family: monospace;
}

/* ── Section Title ───────────────────────────────────────── */
.zra-section-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--dark);
    border-bottom: 2px solid var(--border);
    padding-bottom: 10px;
}

/* ── Module Grid ─────────────────────────────────────────── */
.zra-grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 16px;
}

.zra-module-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px 24px;
    box-shadow: var(--shadow);
    transition: box-shadow .2s, border-color .2s;
}

.zra-module-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,.1);
    border-color: #c7d2fe;
}

.zra-module-done {
    border-color: #86efac;
    background: #f0fdf4;
}

.zra-module-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.zra-module-icon {
    font-size: 28px;
    flex-shrink: 0;
    line-height: 1.2;
}

.zra-module-header > div {
    flex: 1;
    min-width: 0;
}

.zra-module-header h3 {
    font-size: 15px;
    font-weight: 700;
    margin: 0 0 4px;
}

.zra-module-header p {
    font-size: 13px;
    color: var(--gray);
    margin: 0;
}

.zra-module-status {
    font-size: 12px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    white-space: nowrap;
    flex-shrink: 0;
    background: #d1fae5;
    color: #065f46;
}

.zra-coming {
    background: #f3f4f6;
    color: #6b7280;
}

/* ── Help Bar ────────────────────────────────────────────── */
.zra-help-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: var(--radius);
    padding: 16px 24px;
    font-size: 14px;
    color: #1e40af;
    font-weight: 600;
    flex-wrap: wrap;
    gap: 12px;
}

/* ── Small Button ─────────────────────────────────────────── */
.btn-sm {
    padding: 7px 16px;
    font-size: 13px;
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 600px) {
    .zra-page-header { flex-direction: column; align-items: flex-start; }
    .zra-grid-2, .zra-grid-3 { grid-template-columns: 1fr; }
    .zra-help-bar { flex-direction: column; text-align: center; }
}
