/* ProfitGain Main Mobile Dark Theme CSS */

:root {
    --bg-dark: #090a0c;
    --card-bg: #141519;
    --card-bg-light: #1b1c22;
    --primary-gold: #f5b800;
    --primary-gold-hover: #e0a800;
    --gold-glow: rgba(245, 184, 0, 0.25);
    --text-white: #ffffff;
    --text-muted: #9a9ca5;
    --text-gold: #f5b800;
    --border-color: #24262d;
    --accent-red: #ff3b30;
    --accent-green: #22c55e;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: #000000;
    color: var(--text-white);
    display: flex;
    justify-content: center;
    min-height: 100vh;
}

.app-wrapper {
    width: 100%;
    max-width: 480px;
    background-color: var(--bg-dark);
    min-height: 100vh;
    position: relative;
    padding-bottom: 90px; /* Space for bottom nav */
    box-shadow: 0 0 30px rgba(0,0,0,0.8);
    display: flex;
    flex-direction: column;
}

/* Header Navbar */
.app-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background-color: var(--bg-dark);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.app-logo {
    display: flex;
    flex-direction: column;
}

.app-logo .logo-title {
    font-size: 22px;
    font-weight: 800;
    color: var(--primary-gold);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.app-logo .logo-subtitle {
    font-size: 11px;
    color: var(--text-muted);
}

.header-buttons {
    display: flex;
    gap: 10px;
}

.btn-header-login {
    background: #1c1a14;
    border: 1px solid var(--primary-gold);
    color: var(--primary-gold);
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 13px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-header-signup {
    background: var(--primary-gold);
    border: none;
    color: #000;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 13px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* Hero Section */
.hero-card {
    background: linear-gradient(180deg, rgba(80, 60, 0, 0.4) 0%, rgba(20, 20, 20, 0.9) 100%);
    border: 1px solid rgba(245, 184, 0, 0.2);
    border-radius: 20px;
    margin: 15px;
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.hero-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(245, 184, 0, 0.15);
    border-radius: 12px;
    padding: 4px 10px;
    font-size: 11px;
    color: var(--primary-gold);
    margin-bottom: 12px;
}

.hero-title {
    font-size: 22px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 10px;
}

.hero-title span {
    color: var(--primary-gold);
}

.hero-desc {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.4;
    margin-bottom: 18px;
}

.earnings-box {
    background: rgba(0,0,0,0.4);
    border-radius: 14px;
    padding: 14px;
    border: 1px solid rgba(255,255,255,0.05);
    margin-bottom: 15px;
}

.earnings-box .label {
    font-size: 11px;
    color: var(--text-muted);
}

.earnings-box .value {
    font-size: 24px;
    font-weight: 800;
    color: var(--primary-gold);
    margin: 4px 0;
}

.earnings-box .sub-label {
    font-size: 11px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 4px;
}

.chart-preview-img {
    width: 100%;
    border-radius: 14px;
    display: block;
    margin-top: 10px;
}

/* Action Buttons (Create Account / Login) */
.cta-row {
    display: flex;
    gap: 12px;
    padding: 0 15px;
    margin-bottom: 20px;
}

.btn-primary-cta {
    flex: 1;
    background: var(--primary-gold);
    color: #000000;
    border: none;
    padding: 14px;
    border-radius: 25px;
    font-weight: 700;
    font-size: 15px;
    text-align: center;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 15px var(--gold-glow);
}

.btn-secondary-cta {
    flex: 1;
    background: #141518;
    color: #ffffff;
    border: 1px solid #2d2e35;
    padding: 14px;
    border-radius: 25px;
    font-weight: 700;
    font-size: 15px;
    text-align: center;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Section Title */
.section-title {
    font-size: 18px;
    font-weight: 700;
    padding: 0 15px;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.section-subtitle {
    font-size: 12px;
    color: var(--text-muted);
    padding: 0 15px;
    margin-bottom: 15px;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    padding: 0 15px;
    margin-bottom: 25px;
}

.feature-item {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 15px 5px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #fff;
    transition: transform 0.2s;
}

.feature-item:active {
    transform: scale(0.96);
}

.feature-icon-box {
    width: 44px;
    height: 44px;
    background: var(--primary-gold);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #000;
    margin-bottom: 8px;
}

.feature-label {
    font-size: 12px;
    font-weight: 600;
}

/* Grid Menu (Dashboard 12 items) */
.menu-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    padding: 0 15px;
    margin-bottom: 20px;
}

.menu-card {
    background: #141519;
    border: 1px solid rgba(245, 184, 0, 0.2);
    border-radius: 14px;
    padding: 12px 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: var(--text-white);
}

.menu-icon-hex {
    width: 42px;
    height: 42px;
    background: radial-gradient(circle, rgba(245,184,0,0.3) 0%, rgba(20,20,20,0.9) 100%);
    border: 1px solid var(--primary-gold);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: var(--primary-gold);
    margin-bottom: 6px;
}

.menu-title {
    font-size: 11px;
    color: #cccccc;
    text-align: center;
    font-weight: 500;
}

/* Dashboard Balance Card */
.dashboard-user-card {
    padding: 15px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.user-profile-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid var(--accent-red);
    overflow: hidden;
    background: #333;
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-name-box .welcome-tag {
    font-size: 10px;
    color: var(--text-muted);
    letter-spacing: 1px;
}

.user-name-box .user-name {
    font-size: 16px;
    font-weight: 800;
    color: #ffffff;
}

.notification-icon {
    font-size: 20px;
    color: var(--accent-red);
    position: relative;
}

.balance-card {
    background: linear-gradient(135deg, #1f1400 0%, #0d0e12 100%);
    border: 1px solid var(--primary-gold);
    border-radius: 18px;
    margin: 0 15px 15px 15px;
    padding: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.balance-info .bal-label {
    font-size: 11px;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}

.balance-info .bal-amount {
    font-size: 26px;
    font-weight: 800;
    color: #ffffff;
    margin-top: 4px;
}

.balance-wallet-icon {
    width: 45px;
    height: 45px;
    background: var(--accent-red);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: #fff;
}

/* Quick Action Circle Buttons */
.quick-actions-row {
    display: flex;
    justify-content: space-around;
    padding: 0 10px;
    margin-bottom: 20px;
}

.quick-action-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    gap: 6px;
}

.quick-action-circle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: radial-gradient(circle, #e0a800 0%, #664d00 100%);
    border: 2px solid #ffcc00;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(245, 184, 0, 0.3);
}

.quick-action-label {
    font-size: 11px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.5px;
}

/* Referral Box */
.referral-link-box {
    background: rgba(0,0,0,0.6);
    border: 1px dashed rgba(255, 59, 48, 0.5);
    border-radius: 30px;
    margin: 0 15px 20px 15px;
    padding: 10px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.ref-url {
    font-size: 12px;
    color: var(--accent-red);
    font-family: monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 80%;
}

.btn-copy-ref {
    background: #ff5e36;
    border: none;
    color: #fff;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 13px;
    cursor: pointer;
}

/* Stats 2-Column Grid Cards */
.stats-cards-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    padding: 0 15px;
    margin-bottom: 20px;
}

.stat-card {
    background: #121317;
    border: 1px solid var(--primary-gold);
    border-radius: 16px;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.stat-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(245, 184, 0, 0.15);
    color: var(--primary-gold);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.stat-details .stat-val {
    font-size: 15px;
    font-weight: 800;
    color: var(--accent-red);
}

.stat-details .stat-title {
    font-size: 9px;
    color: var(--text-muted);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* Bottom Navigation Bar */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 480px;
    height: 70px;
    background: #0f1013;
    border-top: 1px solid rgba(245, 184, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: space-around;
    z-index: 999;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    text-decoration: none;
    color: var(--text-muted);
    font-size: 11px;
}

.nav-item.active {
    color: var(--accent-red);
}

.nav-item .nav-icon {
    font-size: 20px;
}

.nav-item-circle {
    width: 40px;
    height: 40px;
    background: var(--primary-gold);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000;
    font-size: 18px;
}

/* Floating Telegram Button */
.floating-telegram-btn {
    position: fixed;
    bottom: 85px;
    right: max(15px, calc(50vw - 225px));
    width: 52px;
    height: 52px;
    background: #0088cc;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 26px;
    box-shadow: 0 4px 15px rgba(0, 136, 204, 0.5);
    z-index: 1000;
    text-decoration: none;
    animation: pulse-telegram 2s infinite;
}

@keyframes pulse-telegram {
    0% { box-shadow: 0 0 0 0 rgba(0, 136, 204, 0.7); }
    70% { box-shadow: 0 0 0 14px rgba(0, 136, 204, 0); }
    100% { box-shadow: 0 0 0 0 rgba(0, 136, 204, 0); }
}

/* Forms (Login/Register/Withdraw/Deposit) */
.form-card {
    background: #141519;
    border: 1px solid var(--primary-gold);
    border-radius: 20px;
    margin: 20px 15px;
    padding: 24px 20px;
}

.form-title {
    font-size: 20px;
    font-weight: 700;
    text-align: center;
    color: var(--primary-gold);
    margin-bottom: 6px;
}

.form-subtitle {
    font-size: 12px;
    color: var(--text-muted);
    text-align: center;
    margin-bottom: 24px;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 14px;
    color: var(--primary-gold);
    font-size: 16px;
}

.country-badge {
    position: absolute;
    left: 40px;
    background: rgba(245, 184, 0, 0.2);
    color: var(--primary-gold);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 700;
}

.form-control {
    width: 100%;
    background: #211c14;
    border: 1px solid rgba(245, 184, 0, 0.3);
    border-radius: 12px;
    padding: 14px 14px 14px 44px;
    color: #fff;
    font-size: 14px;
    outline: none;
}

.form-control.has-country {
    padding-left: 85px;
}

.form-control:focus {
    border-color: var(--primary-gold);
    box-shadow: 0 0 8px var(--gold-glow);
}

.btn-submit {
    width: 100%;
    background: var(--primary-gold);
    border: none;
    color: #000;
    padding: 14px;
    border-radius: 25px;
    font-weight: 800;
    font-size: 16px;
    margin-top: 10px;
    cursor: pointer;
}

/* Investment Plan Cards */
.plan-card {
    background: #141722;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    margin: 15px;
    overflow: hidden;
    position: relative;
}

.popular-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--primary-gold);
    color: #000;
    font-size: 11px;
    font-weight: 800;
    padding: 4px 12px;
    border-bottom-left-radius: 10px;
}

.plan-img {
    width: 100%;
    height: 140px;
    object-fit: cover;
}

.plan-body {
    padding: 16px;
}

.plan-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.plan-num-badge {
    background: var(--primary-gold);
    color: #000;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
}

.plan-title {
    font-size: 18px;
    font-weight: 700;
}

.plan-price {
    font-size: 26px;
    font-weight: 800;
    color: var(--primary-gold);
    margin-bottom: 14px;
}

.plan-features-list {
    list-style: none;
    margin-bottom: 18px;
}

.plan-features-list li {
    font-size: 13px;
    color: #d0d0d0;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.plan-features-list li span.highlight {
    color: var(--primary-gold);
    font-weight: 700;
}

/* Alert Boxes */
.alert {
    padding: 12px 16px;
    border-radius: 12px;
    margin: 10px 15px;
    font-size: 13px;
}
.alert-danger { background: rgba(255,59,48,0.2); border: 1px solid var(--accent-red); color: #ff6b6b; }
.alert-success { background: rgba(34,197,94,0.2); border: 1px solid var(--accent-green); color: #4ade80; }
