/* DOCS - Data Operations & Coordination System */
/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --secondary: #06b6d4;
    --accent: #f59e0b;
    --dark: #0f172a;
    --darker: #020617;
    --card: #1e293b;
    --card-hover: #334155;
    --text: #f8fafc;
    --text-muted: #94a3b8;
    --border: #334155;
    --danger: #ef4444;
    --success: #22c55e;
    --warning: #f59e0b;
}

body {
    font-family: 'Inter', 'Noto Sans Thai', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--darker);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Navigation */
.navbar {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--text);
    text-decoration: none;
}

.logo-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 800;
    color: white;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
    font-size: 0.95rem;
}

.nav-links a:hover {
    color: var(--text);
}

.nav-links a.active {
    color: var(--primary);
}

/* Buttons */
.btn {
    padding: 0.625rem 1.25rem;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(99, 102, 241, 0.3);
}

.btn-outline {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border);
}

.btn-outline:hover {
    background: var(--card);
    border-color: var(--primary);
}

.btn-lg {
    padding: 0.875rem 1.75rem;
    font-size: 1rem;
}

.btn-discord {
    background: #5865F2;
    color: white;
}

.btn-discord:hover {
    background: #4752C4;
    transform: translateY(-2px);
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8rem 2rem 4rem;
    background: 
        radial-gradient(ellipse at top, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at bottom, rgba(6, 182, 212, 0.1) 0%, transparent 50%),
        var(--darker);
}

.hero-content {
    text-align: center;
    max-width: 800px;
    margin-bottom: 4rem;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.875rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.badge-dot {
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-desc {
    font-size: 1.125rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    max-width: 1000px;
    width: 100%;
}

.stat-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    transition: all 0.3s;
}

.stat-card:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-info h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.stat-info p {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Services Section */
.services {
    padding: 6rem 0;
    background: var(--dark);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-tag {
    display: inline-block;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary);
    padding: 0.375rem 1rem;
    border-radius: 50px;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 1rem;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.section-header p {
    color: var(--text-muted);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.service-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem;
    transition: all 0.3s;
}

.service-card:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
}

.service-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    margin-bottom: 1.25rem;
}

.service-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.lang-th {
    color: var(--text);
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
}

.lang-en {
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* Contact Section */
.contact {
    padding: 4rem 0;
    background: var(--darker);
}

.contact-card {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(6, 182, 212, 0.1));
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 3rem;
    text-align: center;
}

.contact-content h2 {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}

.contact-content p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

/* Footer */
.footer {
    background: var(--dark);
    border-top: 1px solid var(--border);
    padding: 2rem 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 600;
}

.footer-copy {
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    font-size: 0.9rem;
}

.form-label .required {
    color: var(--danger);
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: 0.875rem 1rem;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text);
    font-size: 0.95rem;
    transition: all 0.3s;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.form-textarea {
    min-height: 120px;
    resize: vertical;
}

.form-hint {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.375rem;
}

/* Checkbox */
.form-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    cursor: pointer;
}

.form-checkbox input {
    width: 20px;
    height: 20px;
    accent-color: var(--primary);
    margin-top: 2px;
}

.form-checkbox .checkbox-text {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.form-checkbox .checkbox-text a {
    color: var(--primary);
    text-decoration: none;
}

.form-checkbox .checkbox-text a:hover {
    text-decoration: underline;
}

/* Page Header */
.page-header {
    padding: 8rem 0 3rem;
    text-align: center;
    background: 
        radial-gradient(ellipse at top, rgba(99, 102, 241, 0.1) 0%, transparent 50%),
        var(--darker);
}

.page-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
}

.page-header p {
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

/* Content Section */
.content-section {
    padding: 3rem 0 6rem;
}

.content-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem;
    max-width: 800px;
    margin: 0 auto;
}

/* Guidelines */
.guidelines-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 2rem;
}

@media (max-width: 768px) {
    .guidelines-grid {
        grid-template-columns: 1fr;
    }
}

.guideline-section h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.guideline-list {
    list-style: none;
}

.guideline-list li {
    padding: 1rem;
    background: rgba(15, 23, 42, 0.5);
    border-radius: 10px;
    margin-bottom: 0.75rem;
    border-left: 3px solid var(--primary);
}

.guideline-list li strong {
    display: block;
    margin-bottom: 0.25rem;
    color: var(--text);
}

.guideline-list li > span {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Admin Dashboard */
.admin-grid {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 2rem;
    align-items: start;
    max-width: 1400px;
    margin: 0 auto;
}

@media (max-width: 1024px) {
    .admin-grid {
        grid-template-columns: 1fr;
    }
}

.sidebar {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
    height: fit-content;
    position: sticky;
    top: 100px;
}

.sidebar-header {
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 1rem;
}

.sidebar-header h3 {
    font-size: 1rem;
}

.sidebar-menu {
    list-style: none;
}

.sidebar-menu li {
    margin-bottom: 0.5rem;
}

.sidebar-menu a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s;
}

.sidebar-menu a:hover {
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary);
}

.sidebar-menu a.active {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(99, 102, 241, 0.1));
    color: var(--primary);
    border-left: 3px solid var(--primary);
    font-weight: 600;
}

.main-content {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem;
}

/* Stats Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.stats-card {
    background: rgba(15, 23, 42, 0.5);
    border-radius: 12px;
    padding: 1.25rem;
}

.stats-card h4 {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.stats-card .value {
    font-size: 1.75rem;
    font-weight: 700;
}

/* Table */
.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.data-table th {
    font-weight: 600;
    color: var(--text-muted);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.data-table tr:hover td {
    background: rgba(99, 102, 241, 0.05);
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 500;
}

.status-pending {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.status-approved {
    background: rgba(34, 197, 94, 0.15);
    color: var(--success);
}

.status-rejected {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

/* Login Form */
.login-container {
    max-width: 420px;
    margin: 0 auto;
}

.login-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 2.5rem;
}

.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-header .logo-icon {
    margin: 0 auto 1rem;
    width: 64px;
    height: 64px;
    font-size: 1.25rem;
}

.login-header h2 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.login-header p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Alerts */
.alert {
    padding: 1rem 1.25rem;
    border-radius: 10px;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.alert-success {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: var(--success);
}

.alert-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: var(--danger);
}

/* Hidden */
.hidden {
    display: none !important;
}

/* Language Switcher */
.lang-switcher {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    margin-left: 1rem;
    padding: 0.25rem;
    background: rgba(30, 41, 59, 0.9);
    border: 1px solid var(--border);
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.lang-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 700;
    transition: all 0.3s;
    min-width: 44px;
}

.lang-btn:hover {
    background: rgba(99, 102, 241, 0.1);
    color: var(--text);
}

.lang-btn.active {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text);
    cursor: pointer;
    padding: 0.5rem;
}

/* Responsive */
@media (max-width: 1024px) {
    .admin-grid {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        margin-bottom: 1rem;
    }
    
    .sidebar-menu {
        display: flex;
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .sidebar-menu li {
        margin-bottom: 0;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }
    
    .hero-title {
        font-size: 1.75rem;
    }
    
    .hero-desc {
        font-size: 1rem;
    }
    
    .hero-cta {
        flex-direction: column;
        width: 100%;
    }
    
    .hero-cta .btn {
        width: 100%;
        justify-content: center;
    }
    
    .nav-container {
        padding: 1rem;
    }
    
    .nav-links {
        gap: 0.5rem;
    }
    
    .nav-links a:not(.btn):not(.logo) {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: block;
    }
    
    .lang-switcher {
        margin-left: 0.5rem;
        padding-left: 0.5rem;
        padding: 0.2rem;
    }
    
    .lang-btn {
        padding: 0.375rem 0.625rem;
        font-size: 0.8rem;
        min-width: 36px;
    }
    
    .section-header h2 {
        font-size: 1.5rem;
    }
    
    .services-grid,
    .hero-stats {
        grid-template-columns: 1fr;
    }
    
    .stat-card {
        flex-direction: row;
    }
    
    .service-card {
        padding: 1.5rem;
    }
    
    .content-card {
        padding: 1.5rem;
    }
    
    .guidelines-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .guideline-list li {
        padding: 0.75rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .data-table {
        font-size: 0.85rem;
    }
    
    .data-table th,
    .data-table td {
        padding: 0.75rem 0.5rem;
    }
    
    .login-card {
        padding: 1.5rem;
    }
    
    .login-header h2 {
        font-size: 1.25rem;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .btn-lg {
        padding: 0.75rem 1.25rem;
        font-size: 0.9rem;
    }
    
    .page-header {
        padding: 6rem 0 2rem;
    }
    
    .page-header h1 {
        font-size: 1.75rem;
    }
    
    .content-section {
        padding: 2rem 0 4rem;
    }
    
    .form-group {
        margin-bottom: 1rem;
    }
    
    .hero {
        padding: 6rem 1rem 3rem;
    }
    
    .services {
        padding: 3rem 0;
    }
    
    .contact-card {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    
    .logo span {
        display: none;
    }
    
    .section-header h2 {
        font-size: 1.25rem;
    }
    
    .data-table {
        font-size: 0.8rem;
    }
    
    .status-badge {
        font-size: 0.7rem;
        padding: 0.25rem 0.5rem;
    }
    
    .btn {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
    }
}
