/* assets/css/style.css - FINAL VERSION (FIXED SPACING FOR OKX HEADER) */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --bg-color: #000000;
    --bg-card: #1F2124;
    --text-color: #FFFFFF;
    --text-sub: #888888;
    --border-color: #333333;
    --primary-btn: #FFFFFF;
    --primary-btn-text: #000000;
    --green: #0ecb81; 
    --red: #f6465d;
    --primary: #f0b90b;
    --header-height: 64px;
}

* { box-sizing: border-box; }
body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: 'Inter', sans-serif;
    margin: 0; padding: 0; line-height: 1.6;
}
a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; padding: 0; margin: 0; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* --- HEADER STYLES (MATCHING OKX) --- */
header {
    background-color: #000000;
    height: var(--header-height);
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    border-bottom: 1px solid #222;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    box-sizing: border-box;
    color: #fff;
}

/* Mobile Header Padding Fix */
@media (max-width: 1024px) {
    header { padding: 0 16px; }
}

footer { padding: 60px 0 30px; background: #000; border-top: 1px solid var(--border-color); text-align: center; color: #555; font-size: 14px; margin-top: auto; }

/* BUTTONS */
.btn { padding: 10px 24px; border-radius: 99px; font-weight: 600; cursor: pointer; border: none; transition: 0.3s; display: inline-block; text-align: center; }
.btn-sm { padding: 8px 16px; font-size: 13px; }
.btn-lg { padding: 14px 40px; font-size: 16px; }
.btn-primary { background: var(--primary-btn); color: var(--primary-btn-text); }
.btn-primary:hover { background: #e6e6e6; transform: translateY(-2px); }
.btn-outline { background: transparent; border: 1px solid var(--border-color); color: #fff; }
.btn-outline:hover { border-color: #fff; background: rgba(255,255,255,0.1); }

/* --- AUTH PAGES (Login/Register) --- */
/* Đã giảm padding-top vì header.php đã có spacer 64px */
.auth-wrapper {
    display: flex; align-items: center; justify-content: center;
    min-height: calc(100vh - 64px); /* Trừ đi header */
    padding-top: 20px; /* Giảm từ 70px xuống 20px */
    padding-bottom: 40px;
    background: radial-gradient(circle at center, #1a1a1a 0%, #000 100%);
}
.auth-card {
    width: 100%; max-width: 420px;
    background: var(--bg-card); padding: 40px;
    border-radius: 16px; border: 1px solid var(--border-color);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}
.auth-title { font-size: 24px; font-weight: 700; text-align: center; margin-bottom: 30px; }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 8px; font-size: 14px; color: var(--text-sub); }
.form-control {
    width: 100%; padding: 12px; background: #2b3139;
    border: 1px solid var(--border-color); border-radius: 8px;
    color: #fff; font-size: 15px; outline: none; transition: 0.3s;
}
.form-control:focus { border-color: var(--primary); }
.error-msg { color: var(--red); font-size: 12px; margin-top: 5px; display: none; }
.auth-footer { text-align: center; margin-top: 20px; font-size: 14px; color: var(--text-sub); }
.auth-footer a { color: var(--primary); font-weight: 600; }

.input-wrapper { position: relative; display: flex; align-items: center; }
.input-icon { position: absolute; left: 15px; color: #848e9c; font-size: 16px; z-index: 2; transition: 0.3s; }
.form-control.with-icon {
    padding-left: 45px; padding-right: 45px; background-color: #2b3139;
    border: 1px solid #474d57; height: 48px; font-size: 15px;
}
.form-control.with-icon:focus { border-color: var(--primary); box-shadow: 0 0 0 1px rgba(240, 185, 11, 0.2); }
.form-control.with-icon:focus + .input-icon { color: var(--primary); }
.toggle-password { position: absolute; right: 15px; color: #848e9c; cursor: pointer; z-index: 2; }
.toggle-password:hover { color: #fff; }
.terms-checkbox { display: flex; align-items: center; gap: 10px; font-size: 14px; color: #848e9c; cursor: pointer; user-select: none; }
.terms-checkbox input { width: 18px; height: 18px; accent-color: var(--primary); cursor: pointer; }

/* --- STATIC PAGES & FAQ --- */
/* Giảm padding-top từ 120px xuống 40px */
.static-page { padding: 40px 0 60px; max-width: 800px; margin: 0 auto; }
.static-page h1 { font-size: 36px; margin-bottom: 30px; }
.static-page h2 { font-size: 24px; margin-top: 30px; margin-bottom: 15px; color: #fff; }
.static-page p, .static-page li { color: #ccc; margin-bottom: 15px; }

.accordion-item { border-bottom: 1px solid var(--border-color); }
.accordion-header {
    width: 100%; padding: 20px 0; background: none; border: none;
    color: #fff; text-align: left; font-size: 16px; font-weight: 600;
    cursor: pointer; display: flex; justify-content: space-between;
}
.accordion-content { display: none; padding-bottom: 20px; color: var(--text-sub); }
.accordion-content.active { display: block; }

/* --- LOCKED PAGE --- */
.locked-container {
    height: calc(100vh - 64px); display: flex; flex-direction: column;
    align-items: center; justify-content: center; text-align: center;
}
.lock-icon { font-size: 80px; color: var(--red); margin-bottom: 30px; }

/* --- LANDING SPECIFIC --- */
/* Giảm padding-top từ 160px xuống 60px */
.hero-section { padding: 60px 0 60px; display: flex; align-items: center; min-height: calc(100vh - 64px); }
.hero-wrap { display: flex; align-items: center; justify-content: space-between; gap: 50px; }
.hero-text { flex: 1; }
.hero-img { flex: 1; text-align: right; }
.hero-img img { max-width: 100%; border-radius: 20px; animation: float 6s ease-in-out infinite; }
@keyframes float { 0% { transform: translateY(0px); } 50% { transform: translateY(-20px); } 100% { transform: translateY(0px); } }
.ticker-wrap { margin-top: 40px; margin-bottom: 80px; }

/* --- PROFILE --- */
/* Giảm margin-top từ 100px xuống 30px */
.profile-container { max-width: 800px; margin: 30px auto 50px; padding: 0 20px; }
.profile-tabs { display: flex; border-bottom: 1px solid #333; margin-bottom: 25px; }
.tab-link { padding: 15px 25px; cursor: pointer; color: #848e9c; font-weight: 600; border-bottom: 2px solid transparent; transition: 0.3s; }
.tab-link:hover { color: #fff; }
.tab-link.active { color: var(--primary); border-bottom-color: var(--primary); }
.tab-pane { display: none; animation: fadeIn 0.3s; }
.tab-pane.active { display: block; }

/* --- REFERRAL --- */
.ref-hero { background: linear-gradient(135deg, #1e2329 0%, #161a1e 100%); padding: 30px; border-radius: 12px; margin-bottom: 30px; border: 1px solid #333; }
.ref-box { background: #000; padding: 15px; border-radius: 8px; border: 1px solid #333; display: flex; justify-content: space-between; align-items: center; margin-top: 15px; }
.ref-link { color: var(--primary); font-family: monospace; font-size: 16px; overflow: hidden; text-overflow: ellipsis; }
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 20px; }
.stat-card { background: #2b3139; padding: 20px; border-radius: 8px; text-align: center; }
.stat-num { font-size: 24px; font-weight: bold; color: #fff; margin-top: 5px; }
.custom-table { width: 100%; border-collapse: collapse; margin-top: 15px; }
.custom-table th { text-align: left; padding: 12px; color: #848e9c; border-bottom: 1px solid #333; font-weight: 500; font-size: 13px; }
.custom-table td { padding: 12px; color: #eaecef; border-bottom: 1px solid #2b3139; font-size: 14px; }

/* --- DASHBOARD SUPER APP --- */
/* Giảm margin-top từ 100px xuống 30px */
.dashboard-container { max-width: 1000px; margin: 30px auto 60px; padding: 0 20px; }

/* Asset Card */
.asset-overview {
    background: linear-gradient(135deg, #1e2329 0%, #161a1e 100%);
    padding: 30px; 
    border-radius: 16px; 
    border: 1px solid #333;
    display: flex; 
    justify-content: space-between; 
    align-items: center;
    margin-bottom: 40px; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    flex-wrap: wrap;
    gap: 20px;
}

.asset-info { flex: 1; min-width: 200px; }
.asset-total label { font-size: 14px; color: #848e9c; display: block; margin-bottom: 5px; }
.asset-total h1 { font-size: 36px; color: #fff; margin: 0; font-weight: 700; letter-spacing: -1px; line-height: 1.2; }
.asset-actions { display: flex; gap: 15px; flex-shrink: 0; }

.btn-icon {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    width: 80px; height: 80px; background: #2b3139; border-radius: 12px;
    color: #fff; font-size: 13px; transition: 0.3s; border: 1px solid transparent;
}
.btn-icon:hover { background: #333; border-color: var(--primary); transform: translateY(-3px); }
.btn-icon i { font-size: 24px; margin-bottom: 8px; color: var(--primary); }

@media (max-width: 768px) {
    .asset-overview { flex-direction: column; align-items: flex-start; }
    .asset-actions { width: 100%; justify-content: space-between; }
    .btn-icon { width: 30%; height: 70px; }
}

/* Status Bar */
.status-bar { display: flex; gap: 20px; margin-bottom: 30px; }
.status-card {
    flex: 1; background: #1e2026; padding: 15px 20px; border-radius: 8px; border: 1px solid #2b3139;
    display: flex; align-items: center; justify-content: space-between;
}
.status-label { font-size: 13px; color: #848e9c; }
.status-val { font-weight: 600; color: #fff; }
.status-btn { font-size: 12px; color: var(--primary); cursor: pointer; }

/* Grid Apps Menu */
.app-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 20px; }
.app-item {
    background: #1F2124; padding: 25px 15px; border-radius: 12px;
    text-align: center; border: 1px solid #2b3139; transition: 0.3s;
    text-decoration: none !important;
}
.app-item:hover { background: #262a30; border-color: #444; transform: translateY(-5px); }
.app-icon {
    width: 50px; height: 50px; background: rgba(255,255,255,0.05);
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    margin: 0 auto 15px; font-size: 24px; color: #fff;
}
.app-name { font-size: 14px; font-weight: 600; color: #eaecef; }
.app-desc { font-size: 12px; color: #848e9c; margin-top: 5px; }

/* Icon Colors */
.icon-bo { color: #0ecb81; background: rgba(14, 203, 129, 0.1); }
.icon-mine { color: #f0b90b; background: rgba(240, 185, 11, 0.1); }
.icon-stock { color: #3b82f6; background: rgba(59, 130, 246, 0.1); }
.icon-earn { color: #a855f7; background: rgba(168, 85, 247, 0.1); }
.icon-vip { color: #f43f5e; background: rgba(244, 63, 94, 0.1); }

/* --- AI / SIGNAL STYLES --- */
.ai-box {
    display: flex; align-items: center;
    padding: 8px 12px; border-radius: 6px; margin-bottom: 10px;
    font-size: 12px; position: relative; overflow: hidden; transition: all 0.3s ease;
}
.ai-buy { background: rgba(14, 203, 129, 0.1); border: 1px solid rgba(14, 203, 129, 0.4); color: #0ecb81; }
.ai-sell { background: rgba(246, 70, 93, 0.1); border: 1px solid rgba(246, 70, 93, 0.4); color: #f6465d; }
.ai-neutral { background: rgba(255, 255, 255, 0.05); border: 1px solid #444; color: #ccc; }
.ai-icon { font-size: 14px; margin-right: 8px; animation: pulse 1.5s infinite; }
.ai-text { flex: 1; font-weight: 500; }
.ai-badge { background: #000; color: #f0b90b; padding: 2px 6px; border-radius: 4px; font-size: 9px; font-weight: 800; }

@keyframes pulse { 0% { opacity: 1; } 50% { opacity: 0.5; } 100% { opacity: 1; } }
@keyframes fadeIn { from { opacity: 0; transform: translateY(-5px); } to { opacity: 1; transform: translateY(0); } }