:root {
    --primary: #4F46E5;
    --primary-hover: #4338CA;
    --secondary: #10B981;
    --bg-color: #F8FAFC;
    --surface: #FFFFFF;
    --text-main: #0F172A;
    --text-muted: #64748B;
    --border: #E2E8F0;
    --radius: 12px;
}
* { margin:0; padding:0; box-sizing:border-box; }
body { 
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; 
    color: var(--text-main); 
    background: var(--bg-color); 
    line-height: 1.6; 
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}
a { color: var(--primary); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--primary-hover); }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* Header & Nav */
.site-header { background: var(--surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 50; }
.nav-wrapper { display: flex; align-items: center; justify-content: space-between; height: 70px; }
.logo { font-weight: 700; font-size: 1.25rem; display: flex; align-items: center; gap: 8px; color: var(--text-main); }
.logo-icon { color: var(--primary); }
.main-nav { display: flex; gap: 24px; align-items: center; font-weight: 500; }
.main-nav a:not(.btn) { color: var(--text-muted); transition: color 0.2s; }
.main-nav a:not(.btn):hover { color: var(--text-main); }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; padding: 10px 20px; border-radius: 8px; font-weight: 500; cursor: pointer; transition: all 0.2s; text-align: center; border: none; font-size: 1rem; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-hover); color: #fff; }
.btn-secondary { background: var(--surface); color: var(--text-main); border: 1px solid var(--border); box-shadow: 0 1px 2px rgb(0 0 0/0.05); }
.btn-secondary:hover { background: #f1f5f9; }
.btn-sm { padding: 8px 16px; font-size: 0.875rem; }
.btn-danger { background: #ef4444; color: white; }
.btn-danger:hover { background: #dc2626; }

/* Grid & Layouts */
.section { padding: 80px 0; }
.section-alt { background: var(--surface); }
.section-header { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 40px; flex-wrap: wrap; gap: 15px; }
.section-header h2 { font-size: 2rem; font-weight: 700; }

/* Site Cards (Directory) */
.site-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 24px; }
.site-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; transition: all 0.2s; display: flex; flex-direction: column; color: var(--text-main); }
.site-card:hover { transform: translateY(-3px); box-shadow: 0 10px 15px -3px rgb(0 0 0/0.05); border-color: #cbd5e1; }
.site-card-header { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.favicon { width: 32px; height: 32px; border-radius: 4px; object-fit: contain; }
.site-titles { flex: 1; min-width: 0; } /* allows truncation if needed */
.site-titles h3 { font-size: 1.125rem; font-weight: 600; line-height: 1.4; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.site-domain { font-size: 0.875rem; color: var(--text-muted); }
.badge { display: inline-flex; align-items: center; justify-content: center; padding: 4px 8px; border-radius: 20px; font-size: 0.75rem; font-weight: 600; white-space: nowrap; }
.badge-verified { background: #dcfce7; color: #166534; }
.badge-pending { background: #fef9c3; color: #854d0e; }
.badge-rejected { background: #fee2e2; color: #991b1b; }
.site-desc { font-size: 0.95rem; color: var(--text-muted); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; margin-bottom: 15px; flex: 1; }
.site-card-footer { border-top: 1px solid var(--border); padding-top: 15px; display: flex; justify-content: space-between; font-size: 0.85rem; color: var(--text-muted); }

/* Home Hero */
.hero { padding: 100px 0; text-align: center; background: linear-gradient(135deg, #eef2ff 0%, #f8fafc 100%); border-bottom: 1px solid var(--border); position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; width: 600px; height: 600px; background: radial-gradient(circle, rgba(79,70,229,0.05) 0%, rgba(255,255,255,0) 70%); top: -100px; left: 50%; transform: translateX(-50%); z-index: 0; pointer-events: none; }
.hero-inner { position: relative; z-index: 1; }
.hero h1 { font-size: 3.5rem; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 1.2rem; color: #1e1b4b; line-height: 1.1; }
.hero-subtitle { font-size: 1.25rem; color: var(--text-muted); max-width: 600px; margin: 0 auto 40px; }
.hero-search { max-width: 650px; margin: 0 auto 40px; display: flex; gap: 10px; background: white; padding: 8px; border-radius: 12px; box-shadow: 0 10px 25px -5px rgb(0 0 0/0.05), 0 8px 10px -6px rgb(0 0 0/0.01); border: 1px solid var(--border); }
.hero-search input { flex: 1; padding: 12px 16px; border: none; font-size: 1rem; outline: none; background: transparent; }
.hero-search .btn { border-radius: 8px; }
.hero-ctas { display: flex; gap: 16px; justify-content: center; }

/* Features Grid */
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 40px; }
.feature { padding: 20px; }
.feature-icon { width: 64px; height: 64px; border-radius: 16px; display: flex; align-items: center; justify-content: center; margin: 0 auto 20px; }
.bg-blue-100 { background: #dbeafe; } .text-blue-600 { color: #2563eb; }
.bg-green-100 { background: #dcfce7; } .text-green-600 { color: #16a34a; }
.bg-purple-100 { background: #f3e8ff; } .text-purple-600 { color: #9333ea; }
.text-center { text-align: center; }

/* Forms */
.form-box { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 40px; box-shadow: 0 4px 6px -1px rgb(0 0 0/0.05); max-width: 600px; margin: 0 auto; }
.form-group { margin-bottom: 24px; }
.form-group label { display: block; font-weight: 600; margin-bottom: 8px; color: var(--text-main); }
.form-control { width: 100%; padding: 12px 16px; border: 1px solid var(--border); border-radius: 8px; font-size: 1rem; outline:none; transition: all 0.2s; font-family: inherit; }
.form-control:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1); }
textarea.form-control { resize: vertical; min-height: 100px; }
.form-text { font-size: 0.85rem; color: var(--text-muted); margin-top: 6px; display: block; }
.alert { padding: 16px; border-radius: 8px; margin-bottom: 24px; font-size: 0.95rem; }
.alert-success { background: #dcfce7; color: #166534; border: 1px solid #bbf7d0; }
.alert-error { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; }
.alert-warning { background: #fef9c3; color: #854d0e; border: 1px solid #fef08a; }

/* Site Profile Pages */
.profile-header { background: var(--surface); border-bottom: 1px solid var(--border); padding: 60px 0; }
.profile-main-info { display: flex; align-items: center; gap: 24px; margin-bottom: 20px; }
.profile-logo { width: 80px; height: 80px; border-radius: 12px; object-fit: contain; background: #fff; border: 1px solid var(--border); padding: 5px; }
.profile-titles h1 { font-size: 2.5rem; line-height: 1.2; margin-bottom: 4px; }
.profile-meta { display: flex; gap: 15px; margin-bottom: 30px; font-size: 0.95rem; color: var(--text-muted); align-items: center; }
.profile-domain-link { display: inline-flex; align-items: center; gap: 8px; background: var(--bg-color); border: 1px solid var(--border); padding: 10px 20px; border-radius: 30px; font-weight: 500; font-size: 1.1rem; color: var(--primary); transition: background 0.2s; }
.profile-domain-link:hover { background: #eef2ff; border-color: #c7d2fe; }
.profile-content { display: grid; grid-template-columns: 2fr 1fr; gap: 40px; }
.content-box { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 30px; margin-bottom: 24px; }
.content-box h3 { margin-bottom: 20px; font-size: 1.25rem; padding-bottom: 10px; border-bottom: 1px solid var(--border); }
.checklist { list-style: none; }
.checklist li { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--border); }
.checklist li:last-child { border-bottom: none; }
.status-yes { color: #16a34a; font-weight: 600; }
.status-no { color: #dc2626; font-weight: 600; }

/* Admin Base styles */
.admin-table { width: 100%; border-collapse: collapse; margin-top: 20px; }
.admin-table th, .admin-table td { padding: 12px 15px; text-align: left; border-bottom: 1px solid var(--border); }
.admin-table th { background: #f8fafc; font-weight: 600; color: var(--text-muted); }

/* Footer */
.site-footer { background: var(--surface); border-top: 1px solid var(--border); padding: 60px 0 20px; margin-top: auto; }
.footer-content { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 40px; margin-bottom: 40px; }
.footer-col h3 { font-size: 1.2rem; margin-bottom: 15px; }
.footer-col h4 { font-size: 1rem; margin-bottom: 15px; color: var(--text-main); }
.footer-col a { display: block; color: var(--text-muted); margin-bottom: 10px; }
.footer-col a:hover { color: var(--primary); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 20px; color: var(--text-muted); font-size: 0.875rem; text-align: center; }

/* Mobile Menu */
@media (max-width: 768px) {
    .hero h1 { font-size: 2.25rem; }
    .hero-search { flex-direction: column; background: transparent; border: none; box-shadow: none; padding: 0; }
    .hero-search input, .hero-search .btn { padding: 15px; border: 1px solid var(--border); margin-bottom: 10px; border-radius: 8px; background: white; }
    .nav-wrapper { flex-direction: column; padding: 15px 0; height: auto; gap: 15px; }
    .profile-content { grid-template-columns: 1fr; }
}
