/* Timestamp Tools - Enhanced to match bot page styling */

.timestamp-tools {
    /* CSS Variables - scoped to timestamp tools */
    --timestamp-primary: #667eea;
    --timestamp-primary-hover: #5a6fd8;
    --timestamp-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --timestamp-gray-50: #f9fafb;
    --timestamp-gray-100: #f3f4f6;
    --timestamp-gray-200: #e5e7eb;
    --timestamp-gray-300: #d1d5db;
    --timestamp-gray-400: #9ca3af;
    --timestamp-gray-500: #6b7280;
    --timestamp-gray-600: #4b5563;
    --timestamp-gray-700: #374151;
    --timestamp-gray-800: #1f2937;
    --timestamp-gray-900: #111827;
    --timestamp-success: #10b981;
    --timestamp-error: #ef4444;
    --timestamp-border-radius: 15px;
    --timestamp-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --timestamp-shadow-md: 0 8px 25px rgba(0, 0, 0, 0.15);
    --timestamp-transition: all 0.3s ease;
    margin: 1.5rem auto;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: var(--timestamp-gray-900);
}

/* Enhanced bot-style header styling */
.page-header .header-icon {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.page-header .header-title {
    font-size: 2rem;
    font-weight: 700;
    color: white;
}

.page-header .header-subtitle {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
}

.page-header .stat-item {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
    position: relative;
    height: 100px; /* Fixed height for equal heights */
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 100px;
}

.page-header .stat-item:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.page-header .stat-number {
    font-size: 1.2rem;
    font-weight: 700;
    color: white;
    word-break: break-all;
}

.page-header .stat-label {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Light mode text color fixes */
[data-theme="light"] .page-header .stat-number {
    color: white !important;
}

[data-theme="light"] .page-header .stat-label {
    color: rgba(255, 255, 255, 0.9) !important;
}

/* Specific gradient class for timestamp tools */
.timestamp-gradient-header {
    background: var(--timestamp-gradient) !important;
    color: white !important;
}

/* Ensure bot-card-header in timestamp tools uses correct gradient */
.timestamp-tools .bot-card-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
    border-radius: 15px 15px 0 0 !important;
    padding: 1.5rem 1.25rem 1rem !important;
    border: none !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Enhanced button styling */
.timestamp-tools .btn-primary {
    background: var(--timestamp-gradient);
    border: none;
    border-radius: 8px;
    transition: var(--timestamp-transition);
}

.timestamp-tools .btn-primary:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4c93 100%);
    transform: translateY(-1px);
    box-shadow: var(--timestamp-shadow);
}

/* Enhanced bot-style header styling */
.page-header .header-icon {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.page-header .header-title {
    font-size: 2rem;
    font-weight: 700;
    color: white;
}

.page-header .header-subtitle {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
}

.page-header .stat-item {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 0.5rem;
}

.page-header .stat-number {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
}

.page-header .stat-label {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Enhanced time item styling */
.timestamp-tools .time-item {
    background: white;
    border: 1px solid var(--timestamp-gray-200);
    border-radius: var(--timestamp-border-radius);
    padding: 1.25rem;
    cursor: pointer;
    transition: var(--timestamp-transition);
    position: relative;
    box-shadow: var(--timestamp-shadow);
}

.timestamp-tools .time-item:hover {
    border-color: var(--timestamp-primary);
    box-shadow: var(--timestamp-shadow-md);
    transform: translateY(-2px);
}

/* Enhanced button styling */
.timestamp-tools .btn-primary {
    background: var(--timestamp-gradient);
    border: none;
    border-radius: 8px;
    transition: var(--timestamp-transition);
}

.timestamp-tools .btn-primary:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4c93 100%);
    transform: translateY(-1px);
    box-shadow: var(--timestamp-shadow);
}

/* Dark mode support */
[data-theme="dark"] .timestamp-tools {
    color: #e5e7eb;
}

[data-theme="dark"] .timestamp-tools .page-header {
    background: var(--timestamp-gradient);
}

[data-theme="dark"] .timestamp-tools .page-header .container-fluid {
    background: var(--timestamp-gradient);
}

[data-theme="dark"] .timestamp-tools .page-header .row {
    background: var(--timestamp-gradient);
}

[data-theme="dark"] .timestamp-tools .page-header .col-lg-6,
[data-theme="dark"] .timestamp-tools .page-header .col-md-12,
[data-theme="dark"] .timestamp-tools .page-header .col-4 {
    background: var(--timestamp-gradient);
}

[data-theme="dark"] .timestamp-tools .time-item {
    background: #1f2937;
    border-color: #374151;
    color: #e5e7eb;
}

[data-theme="dark"] .timestamp-tools .time-item:hover {
    background: #374151;
    border-color: var(--timestamp-primary);
}

[data-theme="dark"] .timestamp-tools .time-label {
    color: #9ca3af;
}

[data-theme="dark"] .timestamp-tools .time-value {
    color: #f3f4f6;
}

[data-theme="dark"] .timestamp-tools .card {
    background: #1f2937;
    border-color: #374151;
    height: 100%; /* Ensure equal height */
    display: flex;
    flex-direction: column;
}

[data-theme="dark"] .timestamp-tools .card-body {
    background: #1f2937;
    color: #e5e7eb;
    flex: 1; /* Allow card body to expand and fill available space */
    padding: 1.5rem; /* Consolidated padding */
}

[data-theme="dark"] .timestamp-tools .form-control {
    background: #374151;
    border-color: #4b5563;
    color: #e5e7eb;
}

[data-theme="dark"] .timestamp-tools .form-control:focus {
    background: #374151;
    border-color: var(--timestamp-primary);
    color: #e5e7eb;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

[data-theme="dark"] .timestamp-tools .form-control::placeholder {
    color: #9ca3af;
}

[data-theme="dark"] .timestamp-tools .form-label {
    color: #f3f4f6;
}

[data-theme="dark"] .timestamp-tools .form-text {
    color: #9ca3af;
}

[data-theme="dark"] .timestamp-tools .result-table {
    background: #374151;
}

[data-theme="dark"] .timestamp-tools .result-table td {
    border-color: #4b5563;
    color: #e5e7eb;
}

[data-theme="dark"] .timestamp-tools .result-label {
    color: #9ca3af;
}

[data-theme="dark"] .timestamp-tools .result-value {
    color: #f3f4f6;
}

[data-theme="dark"] .timestamp-tools .result-card {
    background: #374151;
    border-color: #4b5563;
}

/* Ensure timestamp tools card headers work in both themes */
[data-theme="dark"] .timestamp-tools .bot-card-header,
[data-theme="light"] .timestamp-tools .bot-card-header,
.timestamp-tools .bot-card-header {
    background: var(--timestamp-gradient) !important;
    color: white !important;
    border: none !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
}

/* Enhanced styling for light mode card headers */
[data-theme="light"] .timestamp-tools .bot-card-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2) !important;
}

/* Enhanced styling for dark mode card headers */
[data-theme="dark"] .timestamp-tools .bot-card-header {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4c93 100%) !important;
    color: white !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
}

/* Light mode support (default styling) - only for timestamp tools content */
[data-theme="light"] .timestamp-tools,
.timestamp-tools {
    color: var(--timestamp-gray-900);
}

[data-theme="light"] .timestamp-tools .time-item,
.timestamp-tools .time-item {
    background: white;
    border-color: var(--timestamp-gray-200);
    color: var(--timestamp-gray-900);
}

[data-theme="light"] .timestamp-tools .time-item:hover,
.timestamp-tools .time-item:hover {
    background: var(--timestamp-gray-50);
    border-color: var(--timestamp-primary);
}

[data-theme="light"] .timestamp-tools .time-label,
.timestamp-tools .time-label {
    color: var(--timestamp-gray-600);
}

[data-theme="light"] .timestamp-tools .time-value,
.timestamp-tools .time-value {
    color: var(--timestamp-gray-900);
}

[data-theme="light"] .timestamp-tools .card,
.timestamp-tools .card {
    background: white;
    border-color: var(--timestamp-gray-200);
    height: 100%; /* Ensure equal height */
    display: flex;
    flex-direction: column;
}

[data-theme="light"] .timestamp-tools .card-body,
.timestamp-tools .card-body {
    background: white;
    color: var(--timestamp-gray-900);
    flex: 1; /* Allow card body to expand and fill available space */
    padding: 1.5rem; /* Consolidated padding */
}

[data-theme="light"] .timestamp-tools .form-control,
.timestamp-tools .form-control {
    background: white;
    border-color: var(--timestamp-gray-300);
    color: var(--timestamp-gray-900);
}

[data-theme="light"] .timestamp-tools .form-control:focus,
.timestamp-tools .form-control:focus {
    background: white;
    border-color: var(--timestamp-primary);
    color: var(--timestamp-gray-900);
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

[data-theme="light"] .timestamp-tools .form-control::placeholder,
.timestamp-tools .form-control::placeholder {
    color: var(--timestamp-gray-400);
}

[data-theme="light"] .timestamp-tools .form-label,
.timestamp-tools .form-label {
    color: var(--timestamp-gray-700);
    font-weight: 600;
}

[data-theme="light"] .timestamp-tools .form-text,
.timestamp-tools .form-text {
    color: var(--timestamp-gray-500);
}

[data-theme="light"] .timestamp-tools .result-table,
.timestamp-tools .result-table {
    background: var(--timestamp-gray-50);
    border: 1px solid var(--timestamp-gray-200);
    border-radius: 8px;
}

[data-theme="light"] .timestamp-tools .result-table td,
.timestamp-tools .result-table td {
    border-color: var(--timestamp-gray-200);
    color: var(--timestamp-gray-900);
    padding: 0.75rem;
}

[data-theme="light"] .timestamp-tools .result-label,
.timestamp-tools .result-label {
    color: var(--timestamp-gray-600);
    font-weight: 600;
}

[data-theme="light"] .timestamp-tools .result-value,
.timestamp-tools .result-value {
    color: var(--timestamp-gray-900);
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
}

[data-theme="light"] .timestamp-tools .result-card,
.timestamp-tools .result-card {
    background: var(--timestamp-gray-50);
    border: 1px solid var(--timestamp-gray-200);
    border-radius: 8px;
    margin-top: 1rem;
    padding: 0;
}

/* Enhanced styling for both themes */
.timestamp-tools .result-value:hover {
    background: rgba(102, 126, 234, 0.1);
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

[data-theme="dark"] .timestamp-tools .result-value:hover {
    background: rgba(102, 126, 234, 0.2);
}

/* Copy feedback styling - replaced with toast */
.timestamp-tools .copy-feedback,
.page-header .copy-feedback {
    display: none; /* Hide old feedback */
}

/* Toast notification styling */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
}

.timestamp-toast {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 12px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    margin-bottom: 10px;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
    font-size: 0.9rem;
    font-weight: 500;
    min-width: 200px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.timestamp-toast.show {
    opacity: 1;
    transform: translateX(0);
}

.timestamp-toast.hide {
    opacity: 0;
    transform: translateX(100%);
}

.timestamp-toast i {
    font-size: 1rem;
}

/* Dark mode toast styling */
[data-theme="dark"] .timestamp-toast {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Error toast styling */
.timestamp-toast.error {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}

[data-theme="dark"] .timestamp-toast.error {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
}

/* Ensure box-sizing for all elements */
.timestamp-tools *,
.timestamp-tools *::before,
.timestamp-tools *::after {
    box-sizing: border-box;
}

/* Clean header */
.timestamp-tools .page-header {
    text-align: center;
    padding: 2rem 2rem 1.5rem;
    border-bottom: 1px solid var(--timestamp-gray-200);
}

.timestamp-tools .page-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--timestamp-gray-900);
    margin: 0 0 0.5rem;
}

.timestamp-tools .page-subtitle {
    color: var(--timestamp-gray-500);
    font-size: 0.875rem;
    margin: 0;
}

/* Clean time display */
.timestamp-tools .time-display {
    background: var(--timestamp-gray-50);
    border: 1px solid var(--timestamp-gray-200);
    border-radius: var(--timestamp-border-radius);
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.timestamp-tools .time-header {
    font-size: 1rem;
    font-weight: 600;
    color: var(--timestamp-gray-900);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.timestamp-tools .time-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.timestamp-tools .time-item {
    background: white;
    border: 1px solid var(--timestamp-gray-200);
    border-radius: var(--timestamp-border-radius);
    padding: 1rem;
    cursor: pointer;
    transition: var(--timestamp-transition);
    position: relative;
}

.timestamp-tools .time-item:hover {
    border-color: var(--timestamp-primary);
    box-shadow: var(--timestamp-shadow);
}

.timestamp-tools .time-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--timestamp-gray-500);
    text-transform: uppercase;
    letter-spacing: 0.025em;
    margin-bottom: 0.25rem;
}

.timestamp-tools .time-value {
    font-family: ui-monospace, SFMono-Regular, 'SF Mono', 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--timestamp-gray-900);
    word-break: break-all;
}

/* Clean cards */
.timestamp-tools .tool-card {
    background: white;
    border: 1px solid var(--timestamp-gray-200);
    border-radius: var(--timestamp-border-radius);
    box-shadow: var(--timestamp-shadow);
    margin-bottom: 1.5rem;
    transition: var(--timestamp-transition);
}

.timestamp-tools .tool-card:hover {
    box-shadow: var(--timestamp-shadow-md);
}

.timestamp-tools .card-header {
    background: white;
    border-bottom: 1px solid var(--timestamp-gray-200);
    padding: 1rem 1.5rem;
}

.timestamp-tools .card-title {
    font-size: 1rem;
    font-weight: 600;
    color: #fff;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.timestamp-tools .card-icon {
    color: var(--timestamp-primary);
    font-size: 1rem;
    width: 1rem;
}

/* Clean forms */
.timestamp-tools .form-group {
    margin-bottom: 1.25rem;
}

.timestamp-tools .form-label {
    display: block;
    font-weight: 500;
    color: var(--timestamp-gray-700);
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.timestamp-tools .form-control {
    width: 100%;
    border: 1px solid var(--timestamp-gray-300);
    border-radius: var(--timestamp-border-radius);
    font-size: 0.875rem;
    transition: var(--timestamp-transition);
    background: white;
}

.timestamp-tools .form-control:focus {
    outline: none;
    border-color: var(--timestamp-primary);
    box-shadow: 0 0 0 3px rgb(59 130 246 / 0.1);
}

.timestamp-tools .form-control.is-invalid {
    border-color: var(--timestamp-error);
    animation: timestamp-shake 0.3s ease;
}

.timestamp-tools .monospace {
    font-family: ui-monospace, SFMono-Regular, 'SF Mono', 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
}

.timestamp-tools .input-group {
    display: flex;
    border-radius: var(--timestamp-border-radius);
    overflow: hidden;
}

.timestamp-tools .input-group .form-control {
    border-radius: 0;
    border-right: none;
    flex: 1;
}

.timestamp-tools .input-group .form-control:first-child {
    border-radius: var(--timestamp-border-radius) 0 0 var(--timestamp-border-radius);
}

/* Clean buttons */
.timestamp-tools .btn {
    font-weight: 500;
    font-size: 0.875rem;
    border-radius: var(--timestamp-border-radius);
    border: none;
    cursor: pointer;
    transition: var(--timestamp-transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.timestamp-tools .btn-primary {
    background: var(--timestamp-primary);
    color: white;
    border-radius: 0 var(--timestamp-border-radius) var(--timestamp-border-radius) 0;
}

.timestamp-tools .btn-primary:hover {
    background: var(--timestamp-primary-hover);
}

.timestamp-tools .btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.timestamp-tools .w-100 {
    width: 100%;
    border-radius: var(--timestamp-border-radius);
}

/* Clean results */
.timestamp-tools .result-card {
    background: var(--timestamp-gray-50);
    border: 1px solid var(--timestamp-gray-200);
    border-radius: var(--timestamp-border-radius);
    padding: 1rem;
    margin-top: 1rem;
    animation: timestamp-fadeIn 0.2s ease;
}

.timestamp-tools .result-table {
    width: 100%;
    margin: 0;
}

.timestamp-tools .result-table td {
    padding: 0.75rem 0;
    border: none;
    border-bottom: 1px solid var(--timestamp-gray-200);
    vertical-align: top;
    position: relative;
}

.timestamp-tools .result-table tr:last-child td {
    border-bottom: none;
}

.timestamp-tools .result-label {
    font-weight: 500;
    color: var(--timestamp-gray-600);
    font-size: 0.875rem;
    width: 30%;
}

.timestamp-tools .result-value {
    font-family: ui-monospace, SFMono-Regular, 'SF Mono', 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    font-size: 0.875rem;
    color: var(--timestamp-gray-900);
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    transition: var(--timestamp-transition);
    position: relative;
    word-break: break-all;
}

.timestamp-tools .result-value:hover {
    background: var(--timestamp-gray-100);
}

/* Copy feedback */
.timestamp-tools .copy-feedback {
    position: absolute;
    top: -2rem;
    left: 50%;
    transform: translateX(-50%);
    background: var(--timestamp-gray-900);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    opacity: 0;
    transition: opacity 0.15s;
    pointer-events: none;
    z-index: 10;
    white-space: nowrap;
}

.timestamp-tools .copy-feedback.show {
    opacity: 1;
}

/* Form text */
.timestamp-tools .form-text {
    font-size: 0.75rem;
    color: var(--timestamp-gray-500);
    margin-top: 0.25rem;
}

/* Toast notifications */
.timestamp-tools .toast-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 9999;
}

.timestamp-tools .toast {
    background: white;
    border: 1px solid var(--timestamp-gray-200);
    border-radius: var(--timestamp-border-radius);
    box-shadow: var(--timestamp-shadow-md);
    padding: 1rem;
    margin-bottom: 0.5rem;
    max-width: 300px;
    animation: timestamp-slideIn 0.2s ease;
}

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

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

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

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

@keyframes timestamp-slideOut {
    from { opacity: 1; transform: translateX(0); }
    to { opacity: 0; transform: translateX(100%); }
}

@keyframes timestamp-shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-4px); }
    75% { transform: translateX(4px); }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Apply animations to timestamp tools elements */
.timestamp-tools .conversion-results,
.timestamp-tools .calculation-results,
.timestamp-tools .batch-results {
    animation: fadeInUp 0.4s ease;
}

/* Responsive */
@media (max-width: 768px) {
    .timestamp-tools {
        margin: 1rem;
        border-radius: 0;
    }

    .timestamp-tools .page-header {
        padding: 1.5rem 1rem 1rem;
    }

    .timestamp-tools .time-grid {
        grid-template-columns: 1fr;
    }

    .timestamp-tools .card-body {
        padding: 1rem;
    }

    .timestamp-tools .input-group {
        flex-direction: column;
    }

    .timestamp-tools .input-group .form-control {
        border-radius: var(--timestamp-border-radius);
        border-right: 1px solid var(--timestamp-gray-300);
        margin-bottom: 0.5rem;
    }

    .timestamp-tools .btn-primary {
        border-radius: var(--timestamp-border-radius);
    }
}

/* Dark Mode Support */
[data-theme="dark"] .timestamp-tools {
    /* Dark mode color overrides */
    --timestamp-primary: #60a5fa;
    --timestamp-primary-hover: #3b82f6;
    --timestamp-gray-50: #1f2937;
    --timestamp-gray-100: #374151;
    --timestamp-gray-200: #4b5563;
    --timestamp-gray-300: #6b7280;
    --timestamp-gray-400: #9ca3af;
    --timestamp-gray-500: #d1d5db;
    --timestamp-gray-600: #e5e7eb;
    --timestamp-gray-700: #f3f4f6;
    --timestamp-gray-800: #f9fafb;
    --timestamp-gray-900: #ffffff;
    --timestamp-success: #34d399;
    --timestamp-error: #f87171;
    --timestamp-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.3), 0 1px 2px -1px rgb(0 0 0 / 0.3);
    --timestamp-shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.3), 0 2px 4px -2px rgb(0 0 0 / 0.3);

    background-color: #1f2937;
    color: #ffffff;
}

/* Dark mode specific component styles */
[data-theme="dark"] .timestamp-tools .page-header {
    border-bottom-color: #374151;
}

[data-theme="dark"] .timestamp-tools .time-display {
    background: #374151;
    border-color: #4b5563;
}

[data-theme="dark"] .timestamp-tools .time-item {
    background: #1f2937;
    border-color: #4b5563;
}

[data-theme="dark"] .timestamp-tools .time-item:hover {
    background: #111827;
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.4);
}

[data-theme="dark"] .timestamp-tools .tool-card {
    background: #374151;
    border-color: #4b5563;
}

[data-theme="dark"] .timestamp-tools .card-header {
    background: #1f2937;
    border-bottom-color: #4b5563;
}

[data-theme="dark"] .timestamp-tools .form-control {
    background-color: #1f2937;
    border-color: #4b5563;
    color: #ffffff;
}

[data-theme="dark"] .timestamp-tools .form-control:focus {
    background-color: #111827;
    border-color: #60a5fa;
    box-shadow: 0 0 0 0.2rem rgba(96, 165, 250, 0.25);
    color: #ffffff;
}

[data-theme="dark"] .timestamp-tools .form-control::placeholder {
    color: #9ca3af;
}

[data-theme="dark"] .timestamp-tools .btn-primary {
    background-color: #3b82f6;
    border-color: #3b82f6;
    color: #ffffff;
}

[data-theme="dark"] .timestamp-tools .btn-primary:hover {
    background-color: #2563eb;
    border-color: #2563eb;
}

[data-theme="dark"] .timestamp-tools .btn-primary:focus {
    box-shadow: 0 0 0 0.2rem rgba(96, 165, 250, 0.5);
}

[data-theme="dark"] .timestamp-tools .btn-primary:disabled {
    background-color: #4b5563;
    border-color: #4b5563;
}

[data-theme="dark"] .timestamp-tools .result-card {
    background: #1f2937;
    border-color: #4b5563;
}

[data-theme="dark"] .timestamp-tools .result-table td {
    border-bottom-color: #4b5563;
}

[data-theme="dark"] .timestamp-tools .result-value:hover {
    background: #111827;
}

[data-theme="dark"] .timestamp-tools .form-text {
    color: #9ca3af;
}

[data-theme="dark"] .timestamp-tools .form-label {
    color: #e5e7eb;
}

[data-theme="dark"] .timestamp-tools .result-label {
    color: #d1d5db;
}

[data-theme="dark"] .timestamp-tools .copy-feedback {
    background: #1f2937;
    color: #ffffff;
    border: 1px solid #4b5563;
}

/* Dark mode toast styles */
[data-theme="dark"] .timestamp-tools .toast-success {
    background: #065f46;
    border-color: #059669;
    color: #ffffff;
}

[data-theme="dark"] .timestamp-tools .toast-error {
    background: #7f1d1d;
    border-color: #dc2626;
    color: #ffffff;
}

/* Dark mode input group styles */
[data-theme="dark"] .timestamp-tools .input-group .form-control {
    border-right-color: #4b5563;
}

[data-theme="dark"] .timestamp-tools .input-group .btn {
    border-left-color: #4b5563;
}

/* Dark mode select dropdown styles */
[data-theme="dark"] .timestamp-tools select.form-control option {
    background-color: #1f2937;
    color: #ffffff;
}

[data-theme="dark"] .timestamp-tools select.form-control optgroup {
    background-color: #111827;
    color: #d1d5db;
}

/* Ensure proper contrast for disabled states */
[data-theme="dark"] .timestamp-tools .form-control:disabled {
    background-color: #111827;
    color: #6b7280;
    border-color: #374151;
}

/* Dark mode monospace text */
[data-theme="dark"] .timestamp-tools .monospace,
[data-theme="dark"] .timestamp-tools .result-value {
    color: #f3f4f6;
}

/* Dark mode card icons */
[data-theme="dark"] .timestamp-tools .card-icon {
    color: #60a5fa;
}

/* Dark mode time header */
[data-theme="dark"] .timestamp-tools .time-header {
    color: #e5e7eb;
}

[data-theme="dark"] .timestamp-tools .time-label {
    color: #9ca3af;
}

[data-theme="dark"] .timestamp-tools .time-value {
    color: #ffffff;
}

/* Bootstrap DateTimePicker Theme Support */
.bootstrap-datetimepicker-widget {
    background: var(--card-background) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-color) !important;
    border-radius: 8px !important;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15) !important;
}

.bootstrap-datetimepicker-widget table td,
.bootstrap-datetimepicker-widget table th {
    color: var(--text-color) !important;
    border: none !important;
}

.bootstrap-datetimepicker-widget table td.active,
.bootstrap-datetimepicker-widget table td.active:hover {
    background-color: var(--timestamp-primary) !important;
    color: white !important;
}

.bootstrap-datetimepicker-widget table td:hover {
    background-color: var(--hover-background) !important;
}

.bootstrap-datetimepicker-widget .picker-switch {
    color: var(--text-color) !important;
    font-weight: 600 !important;
}

.bootstrap-datetimepicker-widget .btn {
    background: var(--button-background) !important;
    border-color: var(--border-color) !important;
    color: var(--text-color) !important;
}

.bootstrap-datetimepicker-widget .btn:hover {
    background: var(--hover-background) !important;
}

/* Input group styling for Bootstrap 4 */
.input-group-text {
    background-color: var(--input-background);
    border-color: var(--border-color);
    color: var(--text-color);
    cursor: pointer;
    transition: var(--timestamp-transition);
}

.input-group-text:hover {
    background-color: var(--hover-background);
}

.input-group-append .input-group-text {
    border-left: none;
}

/* Dark mode support for input-group-text */
[data-theme="dark"] .input-group-text {
    background-color: #374151;
    border-color: #4b5563;
    color: #e5e7eb;
}

[data-theme="dark"] .input-group-text:hover {
    background-color: #4b5563;
}

/* Dark mode support for DateTimePicker */
[data-theme="dark"] .bootstrap-datetimepicker-widget {
    background: #1f2937 !important;
    border-color: #374151 !important;
}

[data-theme="dark"] .bootstrap-datetimepicker-widget table td,
[data-theme="dark"] .bootstrap-datetimepicker-widget table th {
    color: #e5e7eb !important;
}

[data-theme="dark"] .bootstrap-datetimepicker-widget table td:hover {
    background-color: #374151 !important;
}

[data-theme="dark"] .bootstrap-datetimepicker-widget .picker-switch {
    color: #e5e7eb !important;
}

[data-theme="dark"] .bootstrap-datetimepicker-widget .btn {
    background: #374151 !important;
    border-color: #4b5563 !important;
    color: #e5e7eb !important;
}

[data-theme="dark"] .bootstrap-datetimepicker-widget .btn:hover {
    background: #4b5563 !important;
}
