:root {
    --primary: #1e3a5f;
    --primary-light: #2563eb;
    --primary-dark: #0f2744;
    --accent: #3b82f6;
    --success: #059669;
    --warning: #d97706;
    --danger: #dc2626;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-500: #64748b;
    --gray-700: #334155;
    --gray-900: #0f172a;
    --white: #ffffff;
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --radius: 12px;
    --font: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: var(--font);
    color: var(--gray-900);
    background: var(--gray-50);
    line-height: 1.6;
    min-height: 100vh;
}

a { color: var(--primary-light); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 1.25rem;
}

/* Header */
.site-header {
    background: var(--white);
    border-bottom: 1px solid var(--gray-200);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.875rem 0;
    gap: 1rem;
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--primary);
}

.logo-link img {
    height: 48px;
    width: auto;
    display: block;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    list-style: none;
}

.nav-links a {
    color: var(--gray-700);
    font-weight: 500;
    font-size: 0.9375rem;
    text-decoration: none;
    transition: color 0.2s;
}

.nav-links a:hover { color: var(--primary-light); }

.lang-switch {
    display: flex;
    gap: 0.25rem;
    background: var(--gray-100);
    border-radius: 8px;
    padding: 0.25rem;
}

.lang-switch a {
    padding: 0.375rem 0.75rem;
    border-radius: 6px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--gray-500);
    text-decoration: none;
    transition: all 0.2s;
}

.lang-switch a.active {
    background: var(--white);
    color: var(--primary);
    box-shadow: var(--shadow);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--primary);
    padding: 0.25rem;
}

/* Hero */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: var(--white);
    padding: 4rem 0;
    text-align: center;
}

.hero h1 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.hero p {
    font-size: 1.125rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

/* Search Card */
.search-section {
    margin-top: -3rem;
    padding-bottom: 3rem;
}

.search-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    padding: 2rem;
    max-width: 640px;
    margin: 0 auto;
}

.search-card label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--gray-700);
}

.search-form {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.search-form input[type="text"] {
    flex: 1;
    min-width: 200px;
    padding: 0.875rem 1rem;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.search-form input[type="text"]:focus {
    outline: none;
    border-color: var(--primary-light);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.btn-primary {
    background: var(--primary-light);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--primary);
    text-decoration: none;
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.search-hint {
    margin-top: 0.75rem;
    font-size: 0.875rem;
    color: var(--gray-500);
}

/* Result Card */
.result-section {
    padding: 0 0 3rem;
}

.result-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    max-width: 720px;
    margin: 0 auto;
    animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.result-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.result-header h2 {
    font-size: 1.25rem;
    color: var(--primary);
}

.result-body { padding: 1.5rem; }

.result-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.25rem;
}

.result-item label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 0.25rem;
}

.result-item span, .result-item p {
    font-size: 1rem;
    color: var(--gray-900);
    font-weight: 500;
}

.result-notice {
    margin-top: 1.25rem;
    padding: 1rem;
    border-radius: 8px;
    font-weight: 500;
}

.result-notice.valid {
    background: #ecfdf5;
    color: var(--success);
    border: 1px solid #a7f3d0;
}

.result-notice.invalid {
    background: #fef2f2;
    color: var(--danger);
    border: 1px solid #fecaca;
}

.result-notice.warning {
    background: #fffbeb;
    color: var(--warning);
    border: 1px solid #fde68a;
}

.result-error {
    text-align: center;
    padding: 2rem;
    color: var(--gray-500);
}

.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.8125rem;
    font-weight: 600;
}

.badge-active { background: #ecfdf5; color: var(--success); }
.badge-expired { background: #fef2f2; color: var(--danger); }
.badge-revoked { background: #f1f5f9; color: var(--gray-700); }
.badge-suspended { background: #fffbeb; color: var(--warning); }

/* About */
.about-section {
    padding: 3rem 0;
    background: var(--white);
    border-top: 1px solid var(--gray-200);
}

.about-section h2 {
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

.about-section p {
    color: var(--gray-700);
    max-width: 720px;
}

/* Footer */
.site-footer {
    background: var(--primary-dark);
    color: rgba(255,255,255,0.8);
    padding: 2rem 0;
    margin-top: auto;
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.site-footer a { color: rgba(255,255,255,0.9); }

/* Mobile */
@media (max-width: 768px) {
    .mobile-menu-btn { display: block; }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        padding: 1rem;
        border-bottom: 1px solid var(--gray-200);
        box-shadow: var(--shadow);
    }

    .nav-links.open { display: flex; }

    .search-form { flex-direction: column; }
    .search-form .btn { width: 100%; }

    .hero { padding: 3rem 0; }
    .search-section { margin-top: -2rem; }
    .search-card { padding: 1.5rem; }
}
