/* 
 * ระบบติดตามสถานะใบอนุญาต - ศูนย์บริการผลิตภัณฑ์สุขภาพเบ็ดเสร็จ สสจ.อุตรดิตถ์
 * ESET-Inspired Theme CSS Styles
 */

/* Thai Font */
body {
    font-family: 'Sarabun', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

/* Color Variables - ESET Theme */
:root {
    --primary-color: #1e3a8a;
    --primary-dark: #1e40af;
    --primary-light: #3b82f6;
    --secondary-color: #64748b;
    --accent-color: #06b6d4;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --info-color: #3b82f6;
    --light-color: #ffffff;
    --dark-color: #1e293b;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    --white: #ffffff;
    --black: #000000;
}

/* Background Gradients - ESET Style */
.bg-gradient-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
}

.bg-gradient-secondary {
    background: linear-gradient(135deg, var(--gray-600) 0%, var(--gray-700) 100%);
}

.bg-gradient-accent {
    background: linear-gradient(135deg, var(--accent-color) 0%, var(--primary-light) 100%);
}

/* Hero Section - ESET Style */
.hero-section {
    min-height: 70vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 50%, var(--accent-color) 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    font-weight: 300;
}

.hero-image {
    animation: float 6s ease-in-out infinite;
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.3));
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(2deg); }
}

/* Cards - ESET Style */
.card {
    border-radius: 12px;
    border: none;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--white);
    overflow: hidden;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.card-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    border: none;
    padding: 1.5rem;
    font-weight: 600;
}

.card-body {
    padding: 2rem;
}

.card-footer {
    background: var(--gray-100);
    border-top: 1px solid var(--gray-200);
    padding: 1.5rem;
}

/* Feature Cards */
.feature-card {
    text-align: center;
    padding: 2rem 1.5rem;
    border-radius: 16px;
    background: var(--white);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.feature-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary-color);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    box-shadow: 0 10px 25px rgba(30, 58, 138, 0.3);
}

.feature-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 1rem;
}

.feature-description {
    color: var(--gray-600);
    line-height: 1.6;
}

/* Info Items */
.info-item {
    margin-bottom: 1rem;
}

.info-item label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-value {
    padding: 0.75rem;
    background: var(--gray-100);
    border-radius: 8px;
    border-left: 4px solid var(--primary-color);
}

/* Timeline Styles - ESET Style */
.timeline {
    position: relative;
    padding: 0;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 0;
    left: 30px;
    height: 100%;
    width: 3px;
    background: linear-gradient(180deg, var(--primary-color) 0%, var(--accent-color) 100%);
    border-radius: 2px;
}

.timeline-item {
    position: relative;
    padding-left: 70px;
    padding-bottom: 2rem;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-marker {
    position: absolute;
    left: 15px;
    top: 0;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--white);
    border: 3px solid var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 14px;
    box-shadow: 0 3px 10px rgba(30, 58, 138, 0.3);
    transition: all 0.3s ease;
}

.timeline-item.active .timeline-marker {
    background: var(--primary-color);
    border-color: var(--primary-dark);
    color: white;
    box-shadow: 0 4px 15px rgba(30, 58, 138, 0.5);
    transform: scale(1.1);
}

.timeline-content {
    background: var(--white);
    padding: 1.25rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(30, 58, 138, 0.15);
    border: 1px solid var(--gray-200);
    transition: all 0.3s ease;
}

.timeline-content:hover {
    transform: translateX(5px);
    box-shadow: 0 6px 20px rgba(30, 58, 138, 0.2);
}

.timeline-title {
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--gray-800);
}

.timeline-description {
    margin-bottom: 0.5rem;
    color: var(--gray-600);
}

/* Buttons - ESET Style */
.btn {
    font-weight: 600;
    border-radius: 8px;
    padding: 0.75rem 1.5rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.875rem;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    border-color: var(--primary-dark);
    color: white;
}

.btn-secondary {
    background: var(--gray-600);
    border-color: var(--gray-600);
    color: white;
}

.btn-secondary:hover {
    background: var(--gray-700);
    border-color: var(--gray-700);
    color: white;
}

.btn-accent {
    background: linear-gradient(135deg, var(--accent-color) 0%, var(--primary-light) 100%);
    border-color: var(--accent-color);
    color: white;
}

.btn-accent:hover {
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--accent-color) 100%);
    border-color: var(--primary-light);
    color: white;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1rem;
    border-radius: 10px;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
    border-radius: 6px;
}

/* Forms - ESET Style */
.form-control {
    border-radius: 8px;
    border: 2px solid var(--gray-300);
    transition: all 0.3s ease;
    background-color: var(--white);
    padding: 0.875rem 1rem;
    font-size: 1rem;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
    background-color: var(--white);
}

.form-control-lg {
    padding: 1.125rem 1.25rem;
    font-size: 1.125rem;
    border-radius: 10px;
}

.form-label {
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--gray-700);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-text {
    font-size: 0.875rem;
    color: var(--gray-500);
}

/* Navigation - ESET Style */
.navbar {
    background: var(--white) !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    padding: 1rem 0;
    transition: all 0.3s ease;
}

.navbar-brand {
    font-weight: 700;
    color: var(--primary-color) !important;
    font-size: 1.5rem;
    text-decoration: none;
}

.navbar-brand:hover {
    color: var(--primary-dark) !important;
    text-decoration: none;
}

.brand-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    box-shadow: 0 4px 15px rgba(30, 58, 138, 0.3);
    transition: all 0.3s ease;
}

.brand-icon:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(30, 58, 138, 0.4);
}

.brand-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1.2;
}

.brand-subtitle {
    font-size: 0.8rem;
    color: var(--gray-600);
    font-weight: 400;
    line-height: 1.2;
}

.nav-link {
    font-weight: 600;
    color: var(--gray-700) !important;
    transition: all 0.3s ease;
    padding: 0.75rem 1rem !important;
    border-radius: 6px;
    margin: 0 0.25rem;
    text-decoration: none;
}

.nav-link:hover {
    color: var(--primary-color) !important;
    background-color: var(--gray-100);
    transform: translateY(-1px);
    text-decoration: none;
}

.nav-link.active {
    color: var(--primary-color) !important;
    background-color: rgba(30, 58, 138, 0.1);
    font-weight: 700;
}

.navbar-toggler {
    border: none;
    padding: 0.5rem;
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
}

/* Dropdown Menu */
.dropdown-menu {
    border: none;
    border-radius: 12px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    padding: 0.5rem;
    margin-top: 0.5rem;
}

.dropdown-item {
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-weight: 500;
    color: var(--gray-700);
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    background-color: var(--gray-100);
    color: var(--primary-color);
    transform: translateX(4px);
}

/* Tables - ESET Style */
.table {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.table th {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    font-weight: 600;
    border: none;
    padding: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.875rem;
}

.table td {
    padding: 1rem;
    border-bottom: 1px solid var(--gray-200);
    vertical-align: middle;
}

.table-hover tbody tr:hover {
    background-color: var(--gray-100);
}

/* Status Badges - ESET Style */
.badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge.bg-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%) !important;
}

.badge.bg-success {
    background: linear-gradient(135deg, var(--success-color) 0%, #059669 100%) !important;
}

.badge.bg-warning {
    background: linear-gradient(135deg, var(--warning-color) 0%, #d97706 100%) !important;
}

.badge.bg-danger {
    background: linear-gradient(135deg, var(--danger-color) 0%, #dc2626 100%) !important;
}

.badge.bg-info {
    background: linear-gradient(135deg, var(--info-color) 0%, #2563eb 100%) !important;
}

/* Alerts - ESET Style */
.alert {
    border-radius: 12px;
    border: none;
    padding: 1.5rem;
    font-weight: 500;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.alert-success {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    color: #065f46;
    border-left: 4px solid var(--success-color);
}

.alert-danger {
    background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
    color: #991b1b;
    border-left: 4px solid var(--danger-color);
}

.alert-warning {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #92400e;
    border-left: 4px solid var(--warning-color);
}

.alert-info {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
    border-left: 4px solid var(--info-color);
}

/* Breadcrumb - ESET Style */
.breadcrumb {
    background: transparent;
    padding: 1rem 0;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "›";
    font-size: 1.2rem;
    color: var(--gray-400);
    font-weight: 600;
}

.breadcrumb-item a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

.breadcrumb-item.active {
    color: var(--gray-600);
    font-weight: 600;
}

/* Footer - ESET Style */
footer {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: var(--white);
    padding: 3rem 0 2rem;
}

footer h5 {
    color: var(--white);
    font-weight: 600;
    margin-bottom: 1.5rem;
}

footer a {
    color: var(--white);
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--accent-color);
}

/* Footer text colors for better readability */
footer .text-muted {
    color: var(--gray-200) !important;
}

footer p {
    color: var(--gray-200);
}

.social-links a {
    display: inline-block;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    color: white;
    border-radius: 50%;
    text-align: center;
    line-height: 40px;
    transition: all 0.3s ease;
    margin-right: 0.75rem;
}

.social-links a:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(30, 58, 138, 0.3);
    color: white;
}

/* Utility Classes */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-light-blue {
    background-color: #eff6ff;
}

.bg-light-gray {
    background-color: var(--gray-100);
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .feature-card {
        margin-bottom: 2rem;
    }
    
    .navbar-nav {
        padding: 1rem 0;
    }
    
    .nav-link {
        padding: 1rem !important;
        margin: 0.25rem 0;
    }
    
    .brand-title {
        font-size: 1rem;
    }
    
    .brand-subtitle {
        font-size: 0.7rem;
    }
    
    .brand-icon {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .timeline::before {
        left: 15px;
    }
    
    .timeline-item {
        padding-left: 50px;
    }
    
    .timeline-marker {
        left: 0;
    }
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .card-body {
        padding: 1.5rem;
    }
    
    .btn-lg {
        padding: 0.875rem 1.5rem;
        font-size: 0.9rem;
    }
    
    .navbar-brand {
        font-size: 1.2rem;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
    from { 
        opacity: 0; 
        transform: translateY(20px);
    }
    to { 
        opacity: 1; 
        transform: translateY(0);
    }
}

.slide-up {
    animation: slideUp 0.8s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--gray-100);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
}

/* Print Styles */
@media print {
    .navbar,
    .breadcrumb,
    .btn,
    .alert,
    footer {
        display: none !important;
    }
    
    .container,
    .container-fluid {
        width: 100% !important;
        max-width: none !important;
    }
    
    .card {
        border: 1px solid var(--gray-300) !important;
        box-shadow: none !important;
    }
}
