/*
 * BKK3PL Custom Styles
 * Consolidated CSS from all templates
 * Generated from CSS migration process
 */

/* ========================================
   CSS CUSTOM PROPERTIES (VARIABLES)
   ======================================== */
:root {
    --primary-color: #0f172a;
    --secondary-color: #00dfff;
    --accent-color: #e74c3c;
    --success-color: #27ae60;
    --warning-color: #f39c12;
    --light-bg: #f8f9fa;
    --brand-navy: #0f172a;
    --brand-slate: #1e293b;
    --brand-cyan: #00dfff;
    --brand-sky: #38bdf8;
    --brand-muted: #64748b;
    --surface-bg: #f8fafc;
    --surface-card: #ffffff;
    --text-main: #0f172a;
    --fs-xs: 0.75rem;
    --fs-sm: 0.8125rem;
    --fs-base: 0.9rem;
    --fs-card-heading: 0.95rem;
    --fs-metric: 1.5rem;
    --line-height-dense: 1.35;
}

/* ========================================
   BASE STYLES
   ======================================== */
body {
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--light-bg);
    color: var(--text-main);
}

/* ========================================
   NAVBAR STYLES
   ======================================== */
.navbar-brand {
    font-weight: bold;
    color: var(--primary-color) !important;
}

.navbar-nav .nav-link {
    font-weight: 500;
}

/* ========================================
   BUTTON STYLES
   ======================================== */
.btn-primary {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
}

.btn-primary:hover {
    background-color: #2980b9;
    border-color: #2980b9;
}

.btn-outline-primary {
    color: var(--secondary-color);
    border-color: var(--secondary-color);
}

.btn-outline-primary:hover {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
}

/* ========================================
   CARD STYLES
   ======================================== */
.card {
    border: none;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* ========================================
   FORM STYLES
   ======================================== */
.form-control:focus {
    border-color: var(--secondary-color);
}

/* ========================================
   DIVIDER TEXT STYLES
   ======================================== */
.divider-text {
    position: relative;
    text-align: center;
    margin: 1rem 0;
}

.divider-text::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #dee2e6;
    box-shadow: 0 0 0 0.2rem rgba(52, 152, 219, 0.25);
}

.divider-text span {
    position: relative;
    z-index: 2;
    padding: 0 1rem;
    font-size: 0.875rem;
}

/* ========================================
   ALERT STYLES
   ======================================== */
.alert {
    border-radius: 8px;
    border: none;
}

.alert-success {
    background-color: #dcfce7;
    color: #14532d;
}

.alert-info {
    background-color: #dbeafe;
    color: #1e3a8a;
}

.alert-warning {
    background-color: #fef3c7;
    color: #78350f;
}

.alert-danger,
.alert-error {
    background-color: #fee2e2;
    color: #7f1d1d;
}

/* ========================================
   LAYOUT STYLES
   ======================================== */
.footer {
    background-color: #0f172a;
    color: #f1f5f9;
    margin-top: auto;
}

.footer a {
    color: #00dfff;
}

.footer a:hover {
    color: #38bdf8;
}

.main-content {
    min-height: calc(100vh - 200px);
}

/* ========================================
   HERO SECTION STYLES
   ======================================== */
.hero-section {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 4rem 0;
}

.hero-icon {
    font-size: 12rem;
    opacity: 0.8;
}

/* ========================================
   AUTH CARD STYLES
   ======================================== */
.auth-card {
    max-width: 400px;
    margin: 2rem auto;
}

/* ========================================
   SOCIAL LOGIN STYLES
   ======================================== */
.social-login-section {
    margin: 1rem 0;
}

.social-btn {
    position: relative;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
}

.social-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    text-decoration: none;
}

.social-btn:active {
    transform: translateY(0);
}

.social-btn i {
    font-size: 1.1rem;
}

/* Provider-specific styling */
.google-btn {
    border-color: #db4437;
    color: #db4437;
}

.google-btn:hover {
    background-color: #db4437;
    border-color: #db4437;
    color: white;
}

.facebook-btn {
    border-color: #4267B2;
    color: #4267B2;
}

.facebook-btn:hover {
    background-color: #4267B2;
    border-color: #4267B2;
    color: white;
}

.github-btn {
    border-color: #333;
    color: #333;
}

.github-btn:hover {
    background-color: #333;
    border-color: #333;
    color: white;
}

.twitter-btn {
    border-color: #1DA1F2;
    color: #1DA1F2;
}

.twitter-btn:hover {
    background-color: #1DA1F2;
    border-color: #1DA1F2;
    color: white;
}

.linkedin-btn {
    border-color: #0077B5;
    color: #0077B5;
}

.linkedin-btn:hover {
    background-color: #0077B5;
    border-color: #0077B5;
    color: white;
}

/* Loading state */
.social-btn.loading {
    pointer-events: none;
    opacity: 0.7;
}

.social-btn.loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    margin: auto;
    border: 2px solid transparent;
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ========================================
   2FA SPECIFIC STYLES
   ======================================== */
.qr-code-img {
    max-width: 200px;
}

.token-input-backup {
    letter-spacing: 0.2em;
}

.token-input-totp {
    letter-spacing: 0.3em;
    font-size: 1.2em;
}

/* ========================================
   LOADING STATES
   ======================================== */
.loading-hidden {
    display: none;
}

/* ========================================
   EMAIL TEMPLATE STYLES
   ======================================== */
.otp-code-text {
    margin: 10px 0 0 0;
    font-size: 14px;
    color: #6c757d;
}

/* ========================================
   RESPONSIVE ADJUSTMENTS
   ======================================== */
@media (max-width: 576px) {
    .social-btn span {
        display: none !important;
    }
    
    .social-btn {
        padding: 0.75rem;
    }
    
    .social-btn i {
        margin: 0 !important;
    }
    
    .hero-icon {
        font-size: 8rem;
    }
}

/* ========================================
   UTILITY CLASSES
   ======================================== */
.text-center {
    text-align: center;
}

.mb-0 {
    margin-bottom: 0;
}

.mt-2 {
    margin-top: 0.5rem;
}

.me-2 {
    margin-right: 0.5rem;
}

.p-3 {
    padding: 1rem;
}

.bg-white {
    background-color: white;
}

.px-3 {
    padding-left: 1rem;
    padding-right: 1rem;
}

.text-muted {
    color: #6c757d;
}

/* ========================================
   DASHBOARD REDESIGN CLASSES
   ======================================== */
.dashboard-layout {
    font-size: var(--fs-base);
    line-height: var(--line-height-dense);
}

.dashboard-layout .card {
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.06);
}

.metric-card {
    position: relative;
    overflow: hidden;
    border-left: 3px solid var(--brand-cyan);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.metric-card::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(125deg, rgba(255, 255, 255, 0.75) 0%, rgba(255, 255, 255, 0) 40%);
}

.metric-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.12);
}

.metric-card .card-body {
    position: relative;
    z-index: 1;
}

.metric-icon-row {
    display: flex;
    align-items: center;
    margin-bottom: 0.25rem;
}

.metric-icon {
    font-size: 0.95rem;
    color: var(--brand-muted);
}

.metric-card--products {
    border-left-color: #2563eb;
}

.metric-card--products .metric-icon {
    color: #2563eb;
}

.metric-card--storage {
    border-left-color: #0891b2;
}

.metric-card--storage .metric-icon {
    color: #0891b2;
}

.metric-card--inbounds {
    border-left-color: #7c3aed;
}

.metric-card--inbounds .metric-icon {
    color: #7c3aed;
}

.metric-card--shipments {
    border-left-color: #ea580c;
}

.metric-card--shipments .metric-icon {
    color: #ea580c;
}

.metric-card .metric-label {
    font-size: var(--fs-xs);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--brand-muted);
}

.metric-card .metric-value {
    font-size: var(--fs-metric);
    font-weight: 700;
    line-height: 1.1;
}

.qa-icon {
    width: 28px;
    min-width: 28px;
    text-align: center;
    font-size: 1.2rem;
    line-height: 1;
}

.bkk-breadcrumb .breadcrumb {
    background: transparent;
    font-size: var(--fs-sm);
}

/* ========================================
   SHOP PLATFORM ICONS
   ======================================== */
.platform-icon-wrap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 0.375rem;
    cursor: default;
}

.platform-icon-wrap:focus-visible {
    outline: 2px solid var(--secondary-color);
    outline-offset: 2px;
}

.platform-icon-sm {
    width: 24px;
    height: 24px;
    display: block;
    border-radius: 0.25rem;
}

.platform-icon-fallback {
    background-color: #e2e8f0;
    color: #334155;
    font-size: 0.65rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

/* ========================================
   DASHBOARD MODERNIZATION 2026
   ======================================== */
.dashboard-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 1rem;
    align-items: flex-start;
}

.dashboard-greeting {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.015em;
}

.dashboard-meta {
    color: #475569;
    font-size: var(--fs-sm);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 600;
}

.setup-progress {
    min-width: 280px;
    max-width: 360px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 0.875rem;
}

.setup-progress__header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.setup-progress__title {
    font-weight: 600;
    color: #334155;
}

.setup-progress__value {
    font-weight: 700;
    color: #0f172a;
}

.setup-progress__track {
    width: 100%;
    height: 0.55rem;
    border-radius: 999px;
    background: #e2e8f0;
    overflow: hidden;
}

.setup-progress__bar {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #2563eb, #06b6d4);
}

.setup-progress__cta {
    display: inline-block;
    margin-top: 0.6rem;
    font-size: var(--fs-sm);
    font-weight: 600;
}

a.metric-card {
    text-decoration: none;
    color: inherit;
    display: block;
}

a.metric-card:focus-visible {
    outline: 3px solid rgba(37, 99, 235, 0.35);
    outline-offset: 2px;
}

a.qa-card {
    text-decoration: none;
    color: var(--text-main);
    border: 1px solid #dbe3ee;
    border-radius: 8px;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
    background: var(--surface-card);
}

a.qa-card:hover {
    border-color: var(--brand-cyan);
    box-shadow: 0 6px 18px rgba(0, 223, 255, 0.14);
    transform: translateY(-2px);
    text-decoration: none;
}

a.qa-card:focus-visible {
    outline: 3px solid rgba(0, 223, 255, 0.45);
    outline-offset: 2px;
    border-color: #06b6d4;
}

.qa-card--primary {
    border-color: #2563eb;
    background: linear-gradient(135deg, #eff6ff 0%, #ecfeff 100%);
}

.qa-card--primary .qa-label,
.qa-card--primary .qa-icon {
    color: #1d4ed8;
    font-weight: 700;
}

.qa-label {
    font-size: var(--fs-sm);
    font-weight: 500;
}

.metric-card:hover,
.metric-card:focus-visible {
    border-color: #7dd3fc;
}

.dashboard-layout a:not(.btn):not(.qa-card):not(.metric-card):not(.nav-link):not(.dropdown-item):not(.card) {
    color: var(--brand-cyan);
    text-decoration: none;
    border-bottom: 1px dotted rgba(0, 223, 255, 0.6);
}

.dashboard-layout a:not(.btn):not(.qa-card):not(.metric-card):not(.nav-link):not(.dropdown-item):not(.card):hover {
    border-bottom-style: solid;
    color: #06b6d4;
}

.section-heading {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.01em;
}

.shipment-chip {
    display: inline-flex;
    align-items: center;
    padding: 0.24rem 0.58rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border: 1px solid transparent;
}

.shipment-chip--neutral {
    color: #334155;
    background: #f1f5f9;
    border-color: #e2e8f0;
}

.shipment-chip--success {
    color: #166534;
    background: #dcfce7;
    border-color: #86efac;
}

.shipment-chip--info {
    color: #0c4a6e;
    background: #e0f2fe;
    border-color: #7dd3fc;
}

.shipment-chip--warning {
    color: #854d0e;
    background: #fef9c3;
    border-color: #fde68a;
}

.shipment-chip--danger {
    color: #991b1b;
    background: #fee2e2;
    border-color: #fca5a5;
}

.empty-state {
    text-align: center;
    padding: 1.25rem 0.75rem;
}

.empty-state__icon {
    font-size: 1.8rem;
    color: #94a3b8;
    margin-bottom: 0.5rem;
}

.empty-state__title {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.empty-state__text {
    color: #64748b;
    margin-bottom: 0.85rem;
}

@media (max-width: 767.98px) {
    .dashboard-greeting {
        font-size: 1.4rem;
    }

    .hide-carrier-mobile {
        display: none !important;
    }
}
