/* LeakShop-inspired Dark Theme CSS */
:root {
    /* Dark theme colors */
    --primary-bg: #0d1117;
    --secondary-bg: #161b22;
    --accent-bg: #21262d;
    --card-bg: #1c2128;
    --border-color: #30363d;
    --hover-bg: #262c36;
    
    /* Text colors */
    --primary-text: #f0f6fc;
    --secondary-text: #8b949e;
    --muted-text: #656d76;
    --link-text: #58a6ff;
    --link-hover: #79c0ff;
    
    /* Accent colors */
    --accent-primary: #238636;
    --accent-hover: #2ea043;
    --accent-secondary: #1f6feb;
    --accent-danger: #da3633;
    --accent-warning: #d29922;
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #238636, #2ea043);
    --gradient-secondary: linear-gradient(135deg, #1f6feb, #58a6ff);
    --gradient-danger: linear-gradient(135deg, #da3633, #f85149);
    
    /* Shadows */
    --shadow-small: 0 1px 3px rgba(0, 0, 0, 0.3);
    --shadow-medium: 0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-large: 0 8px 32px rgba(0, 0, 0, 0.5);
    
    /* Typography */
    --font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans', Helvetica, Arial, sans-serif;
    --font-mono: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
}

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    background: var(--primary-bg);
    color: var(--primary-text);
    line-height: 1.6;
    font-size: 14px;
    overflow-x: hidden;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Header styles */
header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    background: var(--secondary-bg);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
}

/* Logo styles */
.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--primary-text);
}

.logo_sign {
    width: 32px;
    height: 32px;
    background: var(--gradient-primary);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 18px;
    color: white;
    margin-right: 8px;
}

.logo_text {
    font-size: 20px;
    font-weight: 600;
    color: var(--primary-text);
}

/* Navigation menu */
.menu {
    display: flex;
    align-items: center;
    gap: 24px;
}

.menu a {
    color: var(--secondary-text);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
    padding: 8px 12px;
    border-radius: 6px;
}

.menu a:hover,
.menu a.active {
    color: var(--primary-text);
    background: var(--hover-bg);
}

/* Actions area */
.actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.ac_text a {
    color: var(--link-text);
    text-decoration: none;
    font-weight: 500;
    padding: 6px 12px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.ac_text a:hover {
    color: var(--link-hover);
    background: var(--hover-bg);
}

/* Language selector */
.language select {
    background: var(--accent-bg);
    color: var(--primary-text);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 6px 12px;
    font-size: 12px;
    outline: none;
    cursor: pointer;
}

/* Button styles */
.button, .button2, .button3 {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.button2 {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow-small);
}

.button2:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

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

.button3:hover {
    background: var(--hover-bg);
    border-color: var(--accent-secondary);
}

/* Call to action section */
.calltoaction {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 200px);
    padding: 80px 24px;
}

.ca_inner {
    text-align: center;
    max-width: 600px;
}

.cai_title {
    font-size: 48px;
    font-weight: 700;
    color: var(--primary-text);
    margin-bottom: 16px;
    line-height: 1.2;
}

.cai_subtitle {
    font-size: 18px;
    color: var(--secondary-text);
    margin-bottom: 40px;
    line-height: 1.5;
}

.cai_button {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Form styles */
.form-container {
    max-width: 420px;
    margin: 80px auto;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 32px;
    box-shadow: var(--shadow-medium);
}

.form-title {
    font-size: 24px;
    font-weight: 600;
    text-align: center;
    margin-bottom: 24px;
    color: var(--primary-text);
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-weight: 500;
    color: var(--primary-text);
    margin-bottom: 6px;
    font-size: 13px;
}

.form-input {
    width: 100%;
    padding: 12px 16px;
    background: var(--secondary-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--primary-text);
    font-size: 14px;
    transition: all 0.2s ease;
    outline: none;
}

.form-input:focus {
    border-color: var(--accent-secondary);
    box-shadow: 0 0 0 3px rgba(31, 111, 235, 0.1);
}

.form-input::placeholder {
    color: var(--muted-text);
}

.form-button {
    width: 100%;
    padding: 14px;
    background: var(--gradient-primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 8px;
}

.form-button:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-medium);
}

.form-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Card styles */
.card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 16px;
    transition: all 0.2s ease;
}

.card:hover {
    border-color: var(--accent-secondary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--primary-text);
}

.card-content {
    color: var(--secondary-text);
    line-height: 1.6;
}

/* Table styles */
.table {
    width: 100%;
    border-collapse: collapse;
    background: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-small);
}

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

.table th {
    background: var(--secondary-bg);
    font-weight: 600;
    color: var(--primary-text);
    font-size: 13px;
}

.table td {
    color: var(--secondary-text);
}

.table tr:hover td {
    background: var(--hover-bg);
}

/* Status badges */
.badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-success {
    background: rgba(35, 134, 54, 0.2);
    color: var(--accent-primary);
}

.badge-danger {
    background: rgba(218, 54, 51, 0.2);
    color: var(--accent-danger);
}

.badge-warning {
    background: rgba(210, 153, 34, 0.2);
    color: var(--accent-warning);
}

/* Footer styles */
footer {
    background: var(--secondary-bg);
    border-top: 1px solid var(--border-color);
    padding: 32px 24px;
    margin-top: auto;
}

.f_disclaimer {
    text-align: center;
    color: var(--muted-text);
    font-size: 12px;
    line-height: 1.5;
}

/* Utility classes */
.text-primary { color: var(--primary-text); }
.text-secondary { color: var(--secondary-text); }
.text-muted { color: var(--muted-text); }
.text-link { color: var(--link-text); }

.bg-primary { background: var(--primary-bg); }
.bg-secondary { background: var(--secondary-bg); }
.bg-accent { background: var(--accent-bg); }

.d-flex { display: flex; }
.d-block { display: block; }
.d-none { display: none; }

.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.align-center { align-items: center; }

.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }

.p-1 { padding: 8px; }
.p-2 { padding: 16px; }
.p-3 { padding: 24px; }

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }
    
    header {
        padding: 12px 16px;
    }
    
    .cai_title {
        font-size: 32px;
    }
    
    .cai_button {
        flex-direction: column;
        align-items: center;
    }
    
    .button2, .button3 {
        width: 100%;
        max-width: 300px;
    }
    
    .form-container {
        margin: 40px 16px;
        padding: 24px;
    }
    
    .menu {
        display: none;
    }
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideIn {
    from { transform: translateX(-100%); }
    to { transform: translateX(0); }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

.slide-in {
    animation: slideIn 0.4s ease-out;
}

/* Loading spinner */
.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-color);
    border-top: 2px solid var(--accent-secondary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Toast notifications */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 16px;
    box-shadow: var(--shadow-large);
    z-index: 1000;
    max-width: 400px;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.toast.show {
    transform: translateX(0);
}

.toast-success {
    border-left: 4px solid var(--accent-primary);
}

.toast-error {
    border-left: 4px solid var(--accent-danger);
}

.toast-warning {
    border-left: 4px solid var(--accent-warning);
}

/* ========================================
   FINAL POLISHING TOUCHES & ENHANCEMENTS
   ======================================== */

/* Smooth scrolling for the entire page */
html {
    scroll-behavior: smooth;
}

/* Enhanced focus states for accessibility */
*:focus {
    outline: 2px solid var(--accent-secondary);
    outline-offset: 2px;
}

/* Remove outline for mouse users */
*:focus:not(:focus-visible) {
    outline: none;
}

/* Enhanced button interactions */
.button, .button2, .button3, .form-button {
    position: relative;
    overflow: hidden;
}

.button::after, .button2::after, .button3::after, .form-button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
    pointer-events: none;
}

.button:active::after, .button2:active::after, .button3:active::after, .form-button:active::after {
    width: 300px;
    height: 300px;
}

/* Enhanced card hover effects */
.card {
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(16, 185, 129, 0.05));
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: inherit;
    pointer-events: none;
}

.card:hover::before {
    opacity: 1;
}

/* Skeleton loading animations */
.skeleton {
    background: linear-gradient(90deg, var(--border-color) 25%, var(--hover-bg) 50%, var(--border-color) 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    border-radius: 4px;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Enhanced table animations */
.table tr {
    transition: all 0.2s ease;
}

.table tbody tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.02);
}

.table tbody tr:hover {
    background: var(--hover-bg);
    transform: scale(1.01);
    box-shadow: var(--shadow-small);
}

/* Progress indicators */
.progress-bar {
    width: 100%;
    height: 4px;
    background: var(--border-color);
    border-radius: 2px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: 2px;
    transition: width 0.3s ease;
    position: relative;
}

.progress-bar-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Enhanced form animations */
.form-input {
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.form-input:focus {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(31, 111, 235, 0.15);
}

.form-group {
    position: relative;
}

.form-group::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--accent-primary);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.form-group:focus-within::after {
    width: 100%;
}

/* Enhanced navigation active states */
.menu a.active {
    position: relative;
}

.menu a.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent-primary);
    border-radius: 1px;
}

/* Smooth page transitions */
.page-transition-enter {
    opacity: 0;
    transform: translateY(20px);
}

.page-transition-enter-active {
    opacity: 1;
    transform: translateY(0);
    transition: all 0.3s ease-out;
}

.page-transition-exit {
    opacity: 1;
    transform: translateY(0);
}

.page-transition-exit-active {
    opacity: 0;
    transform: translateY(-20px);
    transition: all 0.3s ease-in;
}

/* Enhanced toast notifications */
.toast {
    animation: toastSlide 0.3s ease-out;
}

@keyframes toastSlide {
    from {
        opacity: 0;
        transform: translateX(100%) translateY(-50%);
    }
    to {
        opacity: 1;
        transform: translateX(0) translateY(0);
    }
}

.toast.removing {
    animation: toastSlideOut 0.3s ease-in forwards;
}

@keyframes toastSlideOut {
    from {
        opacity: 1;
        transform: translateX(0) translateY(0);
    }
    to {
        opacity: 0;
        transform: translateX(100%) translateY(-50%);
    }
}

/* Enhanced modal animations */
.modal-overlay {
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal {
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Parallax effect for hero sections */
.hero-parallax {
    position: relative;
    overflow: hidden;
}

.hero-parallax::before {
    content: '';
    position: absolute;
    top: -10%;
    left: -10%;
    right: -10%;
    bottom: -10%;
    background: inherit;
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) translateX(0px); }
    33% { transform: translateY(-10px) translateX(5px); }
    66% { transform: translateY(5px) translateX(-5px); }
}

/* Enhanced scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--primary-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
    transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-secondary);
}

/* Selection styling */
::selection {
    background: rgba(59, 130, 246, 0.3);
    color: var(--primary-text);
}

::-moz-selection {
    background: rgba(59, 130, 246, 0.3);
    color: var(--primary-text);
}

/* Print styles */
@media print {
    :root {
        --primary-bg: white;
        --secondary-bg: white;
        --primary-text: black;
        --secondary-text: #666;
    }

    .no-print {
        display: none !important;
    }

    .card {
        box-shadow: none;
        border: 1px solid #ddd;
    }

    body {
        background: white;
        color: black;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --border-color: #ffffff;
        --primary-text: #ffffff;
        --secondary-text: #cccccc;
    }

    .card {
        border-width: 2px;
    }

    .button, .button2, .button3 {
        border-width: 2px;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    .card:hover {
        transform: none;
    }
}

/* Dark mode refinements */
@media (prefers-color-scheme: dark) {
    :root {
        color-scheme: dark;
    }
}

/* Enhanced utility classes */
.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.blur-backdrop {
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.glass-effect {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Enhanced error states */
.error-shake {
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

/* Success pulse animation */
.success-pulse {
    animation: successPulse 0.6s ease-out;
}

@keyframes successPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Enhanced loading states */
.loading-dots::after {
    content: '';
    animation: dots 1.5s infinite;
}

@keyframes dots {
    0%, 20% { content: ''; }
    40% { content: '.'; }
    60% { content: '..'; }
    80%, 100% { content: '...'; }
}

/* Micro-interactions for better UX */
.interactive-scale {
    transition: transform 0.2s ease;
}

.interactive-scale:hover {
    transform: scale(1.02);
}

.interactive-scale:active {
    transform: scale(0.98);
}

/* Enhanced status indicators */
.status-indicator {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    position: relative;
}

.status-indicator::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border-radius: 50%;
    border: 2px solid currentColor;
    opacity: 0;
    animation: ping 2s infinite;
}

.status-indicator.online {
    background: var(--accent-primary);
    color: var(--accent-primary);
}

.status-indicator.offline {
    background: var(--accent-danger);
    color: var(--accent-danger);
}

@keyframes ping {
    0% { opacity: 1; transform: scale(0.8); }
    75%, 100% { opacity: 0; transform: scale(2); }
}

