:root {
    --bg-dark: #020617;
    --bg-card: #0f172a;
    --primary: #3b82f6;
    --accent: #10b981;
    --wolf-gold: #fbbf24;
    --text: #f8fafc;
    --text-dim: #94a3b8;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Segoe UI', system-ui, sans-serif; }

body { background: var(--bg-dark); color: var(--text); min-height: 100vh; display: flex; flex-direction: column; }

.hidden-until-loaded { visibility: hidden; }

.navbar {
    display: flex; justify-content: space-between; align-items: center;
    padding: 15px 20px; background: #0f172a;
    border-bottom: 1px solid #1e293b; position: sticky; top: 0; z-index: 100;
}
.logo { font-size: 1.5rem; font-weight: 900; color: white; text-decoration: none; display: flex; align-items: center; gap: 8px;}
.logo span { color: var(--primary); }

.btn-primary, .btn-outline, .btn-whatsapp, .btn-unlock {
    padding: 12px 20px; border-radius: 8px; font-weight: 600; cursor: pointer; border: none;
    text-align: center; text-decoration: none; display: block; width: 100%; transition: all 0.2s;
}
.btn-primary { background: var(--primary); color: white; }
.btn-outline { background: transparent; border: 1px solid var(--primary); color: var(--text); width: auto; display: inline-block; }
.btn-whatsapp { background: var(--accent); color: white; margin-top: 10px; }
.btn-unlock { background: var(--wolf-gold); color: #000; margin-top: 15px; }
.btn-danger { background: #ef4444; color: white; border: none; padding: 8px 15px; border-radius: 6px; cursor: pointer; }

.container { padding: 15px; max-width: 800px; margin: 0 auto; flex: 1; width: 100%; }

.hero { text-align: center; padding: 25px 10px 15px 10px; }
.hero h1 { font-size: 2rem; margin-bottom: 10px; text-shadow: 0 4px 10px rgba(59, 130, 246, 0.5); }
.hero p { color: var(--text-dim); font-size: 0.95rem; }

.paw-section, .profile-section { background: var(--bg-card); padding: 20px; border-radius: 12px; border: 1px solid #1e293b; margin-bottom: 20px; }
.paw-section h2, .premium-section h2 { margin-bottom: 10px; font-size: 1.3rem; text-align: center;}
.paw-section p { margin-bottom: 15px; color: var(--text-dim); font-size: 0.95rem; text-align: center;}

.match-table { width: 100%; background: var(--bg-card); border-radius: 12px; border: 1px solid #1e293b; overflow: hidden; margin-bottom: 15px; }
.match-row { display: flex; justify-content: space-between; padding: 12px 15px; border-bottom: 1px solid #1e293b; align-items: center; }
.match-row:last-child { border-bottom: none; }
.match-label { color: var(--text-dim); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 1px; }
.match-value { font-weight: bold; font-size: 1rem; }
.status-badge { padding: 4px 10px; border-radius: 20px; font-size: 0.75rem; font-weight: bold; text-transform: uppercase; }
.status-pending { background: #eab30833; color: #facc15; border: 1px solid #facc15; }
.status-won { background: #10b98133; color: #34d399; border: 1px solid #34d399; }
.status-lost { background: #ef444433; color: #f87171; border: 1px solid #f87171; }
.hidden-value { color: #ef4444; filter: blur(4px); user-select: none; }

input, select { width: 100%; padding: 14px; margin-bottom: 15px; background: var(--bg-dark); border: 1px solid #1e293b; border-radius: 8px; color: white; }
input[type="checkbox"] { width: auto; margin-right: 10px; }

.auth-wrapper { display: flex; flex-direction: column; justify-content: center; align-items: center; min-height: 80vh; padding: 20px; }
.auth-box { width: 100%; max-width: 400px; background: var(--bg-card); padding: 30px; border-radius: 12px; border: 1px solid #1e293b; }

.footer { text-align: center; padding: 30px 20px; background: var(--bg-card); margin-top: auto; border-top: 1px solid #1e293b; }
.footer a { color: var(--text-dim); text-decoration: none; margin: 0 10px; font-size: 0.9rem; }
.footer-socials { margin: 15px 0; }
.footer-socials a { color: var(--primary); font-size: 1.5rem; margin: 0 10px; }

.profile-header { display: flex; align-items: center; gap: 20px; margin-bottom: 20px; }
.avatar-container { position: relative; width: 80px; height: 80px; border-radius: 50%; overflow: hidden; border: 2px solid var(--primary); flex-shrink: 0;}
.avatar-container img { width: 100%; height: 100%; object-fit: cover; }

/* === CHAT SYSTEM (Fixed Scrolling & Flex Layout) === */
.chat-toggle-btn { position: fixed; bottom: 20px; right: 20px; background: var(--primary); width: 60px; height: 60px; border-radius: 50%; display: flex; justify-content: center; align-items: center; box-shadow: 0 4px 15px rgba(0,0,0,0.5); cursor: pointer; z-index: 999; }
.chat-toggle-btn i { font-size: 28px; color: white; }

.chat-widget { 
    position: fixed; bottom: 90px; right: 20px; width: 340px; 
    max-height: 75vh; 
    background: var(--bg-card); border-radius: 12px; border: 1px solid #1e293b; 
    z-index: 1000; display: none; flex-direction: column; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.8); overflow: hidden; transition: all 0.3s; 
}
.chat-fullscreen { top: 0; left: 0; width: 100%; height: 100%; max-height: 100vh; bottom: 0; right: 0; border-radius: 0; bottom: 0 !important; }

.chat-header { background: var(--primary); padding: 15px; font-weight: bold; color: white; display: flex; justify-content: space-between; align-items: center; flex-shrink: 0; }
.chat-messages { flex: 1 1 auto; overflow-y: auto; padding: 15px; display: flex; flex-direction: column; gap: 10px; background: var(--bg-dark); }
.chat-msg { padding: 10px 14px; border-radius: 12px; max-width: 85%; font-size: 0.95rem; word-wrap: break-word; }
.chat-msg img { max-width: 100%; border-radius: 8px; margin-top: 5px; }
.msg-admin { background: #334155; align-self: flex-start; border-bottom-left-radius: 2px;}
.msg-user { background: var(--primary); align-self: flex-end; color: white; border-bottom-right-radius: 2px;}

.chat-emoji-bar { background: var(--bg-card); padding: 5px 10px; display: flex; gap: 10px; border-top: 1px solid #1e293b; flex-shrink: 0; }
.chat-emoji-bar span { cursor: pointer; font-size: 1.2rem; transition: transform 0.2s;}
.chat-emoji-bar span:active { transform: scale(1.2); }

.chat-input-area { display: flex; padding: 10px; background: var(--bg-card); align-items: center; border-radius: 0 0 12px 12px; flex-shrink: 0; }
.chat-input-area input[type="text"] { flex: 1; margin: 0; background: var(--bg-dark); border: none; border-radius: 20px; padding: 10px 15px; }
.chat-icon-btn { background: transparent; color: var(--primary); font-size: 1.2rem; border: none; padding: 10px; cursor: pointer; display: flex; align-items: center; justify-content: center;}

.flex { display: flex; gap: 20px; flex-wrap: wrap; }
.col { flex: 1; min-width: 300px; }
