:root { --primary: #0F0F0F; --accent: #185ADB; --bg: #F9F9F9; --white: #FFFFFF; --danger: #DC3545; --text: #333; }
body { font-family: 'Segoe UI', sans-serif; margin: 0; background: var(--bg); color: var(--text); line-height: 1.6; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 20px; }
.hidden { display: none !important; }

/* BUTTONS */
.btn { padding: 12px 24px; border: none; cursor: pointer; border-radius: 5px; font-weight: bold; text-decoration: none; display: inline-block; transition: 0.3s; color: white; }
.btn-primary { background: var(--accent); } .btn-primary:hover { background: #1243a6; }
.btn-secondary { background: #ddd; color: #333; cursor: not-allowed; }
.btn-danger { background: white; color: var(--danger); border: 1px solid var(--danger); font-size: 0.8rem; padding: 5px 10px; }
.btn-danger:hover { background: var(--danger); color: white; }
.btn-warning { background: #ffc107; color: #333; font-size: 0.8rem; padding: 5px 10px; }

/* NAV & HEADER */
.top-bar { background: #333; color: #ccc; text-align: center; font-size: 0.75rem; padding: 8px; }
nav { background: var(--white); padding: 15px 0; position: sticky; top: 0; z-index: 100; box-shadow: 0 2px 10px rgba(0,0,0,0.1); }
.nav-container { display: flex; justify-content: space-between; align-items: center; }
.logo { font-size: 1.5rem; font-weight: 800; color: var(--primary); text-decoration: none; }
.logo span { color: var(--accent); }

/* DROPDOWN MENU */
.dropdown { position: relative; display: inline-block; }
.dropbtn { background-color: transparent; color: var(--primary); padding: 10px; font-size: 1rem; border: none; cursor: pointer; font-weight: bold; display: flex; align-items: center; }
.dropdown-content { display: none; position: absolute; right: 0; background-color: #f9f9f9; min-width: 180px; box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2); z-index: 1000; border-radius: 5px; overflow: hidden; }
.dropdown-content a, .dropdown-content button { color: black; padding: 12px 16px; text-decoration: none; display: block; text-align: left; background:none; border:none; width:100%; font-size:1rem; cursor:pointer; font-family: inherit; }
.dropdown-content a:hover, .dropdown-content button:hover {background-color: #f1f1f1;}
.dropdown:hover .dropdown-content {display: block;}

/* AVATARS */
.nav-avatar { width: 30px; height: 30px; border-radius: 50%; vertical-align: middle; margin-right: 8px; border: 1px solid #ddd; object-fit: cover; }
.large-avatar { width: 100px; height: 100px; border-radius: 50%; border: 3px solid var(--accent); object-fit: cover; margin-bottom: 10px; }

/* HERO SECTION */
.hero { background: linear-gradient(135deg, #0F0F0F 0%, #2c3e50 100%); color: var(--white); text-align: center; padding: 100px 20px; }
.hero h1 { margin: 0 0 15px; font-size: 2.5rem; }

/* CARDS & GRIDS */
.code-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 25px; margin-top: 30px; }
.code-card { background: var(--white); padding: 25px; border-radius: 12px; text-align: center; border: 1px solid #eee; box-shadow: 0 4px 15px rgba(0,0,0,0.05); position: relative; }
.code-display { font-size: 2rem; font-family: monospace; color: var(--accent); margin: 15px 0; background: #f0f4ff; padding: 15px; border-radius: 8px; border: 2px dashed #dbeafe; }
.report-section { margin-top: 20px; display: flex; justify-content: space-between; align-items: center; font-size: 0.8rem; color: #777; }

/* FORMS & SETTINGS */
.bg-light { background: #e9ecef; padding: 80px 0; }
.submission-container { max-width: 500px; background: var(--white); padding: 40px; border-radius: 15px; margin: 0 auto; box-shadow: 0 10px 30px rgba(0,0,0,0.1); }
.form-group { margin-bottom: 15px; } .form-group input, .form-group select { width: 100%; padding: 10px; box-sizing: border-box; border: 1px solid #ddd; border-radius: 5px; }
.modal { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.6); display: flex; justify-content: center; align-items: center; z-index: 1000; backdrop-filter: blur(5px); }
.modal-content { background: white; padding: 40px; border-radius: 12px; text-align: center; }
.modal-actions { margin-top: 20px; gap: 10px; display: flex; justify-content: center; }

/* SETTINGS PAGE */
.settings-grid { display: grid; grid-template-columns: 250px 1fr; gap: 30px; }
.settings-card { background: white; padding: 30px; border-radius: 12px; box-shadow: 0 4px 15px rgba(0,0,0,0.05); }
.settings-menu { list-style: none; padding: 0; }
.settings-menu li a { display: block; padding: 12px 15px; text-decoration: none; color: #333; border-radius: 5px; margin-bottom: 5px; transition: 0.2s; }
.settings-menu li a:hover, .settings-menu li a.active { background: #eef2ff; color: var(--accent); font-weight: bold; }
.password-policy-box { background: #f8f9fa; padding: 15px; border-radius: 5px; border-left: 4px solid var(--accent); margin-bottom: 20px; font-size: 0.9rem; }
.password-policy-box ul { margin: 5px 0 0 20px; padding: 0; }
@media (max-width: 768px) { .settings-grid { grid-template-columns: 1fr; } }

/* ADMIN */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; margin-bottom: 30px; }
.stat-card { background: white; padding: 20px; border-radius: 10px; border: 1px solid #eee; text-align: center; }
.stat-number { font-size: 2rem; font-weight: bold; color: var(--accent); display: block; }
.admin-tabs { display: flex; gap: 10px; margin-bottom: 20px; border-bottom: 2px solid #eee; padding-bottom: 10px; overflow-x: auto;}
.tab-btn { background: none; border: none; font-size: 1rem; color: #666; cursor: pointer; padding: 10px 20px; font-weight: bold; white-space: nowrap; }
.tab-btn.active { color: var(--accent); border-bottom: 3px solid var(--accent); margin-bottom: -12px; }
.badge { display: inline-block; padding: 3px 8px; border-radius: 12px; font-size: 0.75rem; color: white; margin-bottom: 5px; }
.bg-green { background: #28a745; } .bg-red { background: #dc3545; } .bg-blue { background: #185ADB; }

/* FOOTER & COMPLIANCE */
footer { background: var(--primary); color: #ccc; padding: 40px 0; text-align: center; font-size: 0.9rem; }
footer a { color: #fff; text-decoration: none; margin: 0 10px; }
footer a:hover { text-decoration: underline; }
#toast { visibility: hidden; min-width: 250px; background-color: #333; color: #fff; text-align: center; border-radius: 5px; padding: 16px; position: fixed; z-index: 2000; left: 50%; bottom: 30px; transform: translateX(-50%); font-size: 17px; opacity: 0; transition: opacity 0.5s; }
#toast.show { visibility: visible; opacity: 1; bottom: 50px; }
#cookie-banner { position: fixed; bottom: 0; left: 0; width: 100%; background-color: #fff; border-top: 1px solid #ccc; padding: 20px; box-shadow: 0 -4px 10px rgba(0,0,0,0.1); display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 15px; z-index: 9999; transform: translateY(100%); transition: transform 0.3s ease-in-out; text-align: center; }
#cookie-banner.active { transform: translateY(0); }
#cookie-banner p { margin: 0; font-size: 0.95rem; color: #333; max-width: 800px; }
.cookie-buttons { display: flex; gap: 15px; }
@media (max-width: 600px) { #cookie-banner { padding: 15px; } .cookie-buttons { width: 100%; justify-content: center; } .cookie-buttons button { flex: 1; } }

.share-container { margin-top: 30px; text-align: center; padding: 20px; background: #f9f9f9; border-radius: 10px; }
.share-btn { display: inline-block; background: #ccc; color: white; padding: 8px 15px; margin: 5px; border-radius: 4px; text-decoration: none; font-size: 0.9rem; font-weight: bold; }
.share-fb { background: #3b5998; } .share-tw { background: #1DA1F2; } .share-rd { background: #FF5700; }
.info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 30px; margin: 40px 0; }
.info-card { background: #fff; padding: 25px; border-radius: 10px; border: 1px solid #eee; text-align: center; }
.step-number { background: var(--accent); color: white; width: 30px; height: 30px; border-radius: 50%; display: inline-block; line-height: 30px; font-weight: bold; margin-bottom: 10px; }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
@media (max-width: 768px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-info-box { background: #f8f9fa; padding: 20px; border-radius: 8px; border-left: 4px solid var(--accent); margin-top: 30px; }
textarea { resize: vertical; }

a:focus, button:focus, input:focus, select:focus, textarea:focus, .share-btn:focus { outline: 3px solid var(--accent); outline-offset: 2px; }

/* ACCESSIBILITY UTILITIES (WCAG 2.1 AA) */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--accent);
    color: white;
    padding: 8px;
    z-index: 2000;
    transition: top 0.3s;
    text-decoration: none;
    font-weight: bold;
}
.skip-link:focus {
    top: 0;
}