/* Bold Text Generator Styles */

/* Toggle Switch Styles */
.toggle-switch {
    position: relative;
    width: 44px;
    height: 24px;
    background-color: #d1d5db;
    border-radius: 12px;
    transition: background-color 0.3s ease;
    cursor: pointer;
}

.toggle-switch .toggle-dot {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background-color: white;
    border-radius: 50%;
    transition: transform 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

input:checked + .toggle-switch {
    background-color: #8b5cf6;
}

input:checked + .toggle-switch .toggle-dot {
    transform: translateX(20px);
}

/* Category Tab Styles */
.category-tab {
    position: relative;
    transition: all 0.2s ease;
}

.category-tab.active::before {
    content: "";
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #8b5cf6, #3b82f6);
    border-radius: 2px 2px 0 0;
}

/* Style Card Animations */
.style-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.style-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Button Hover Effects */
.copy-btn {
    position: relative;
    overflow: hidden;
}

.copy-btn::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.copy-btn:hover::before {
    left: 100%;
}

/* Loading Animation */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.animate-spin {
    animation: spin 1s linear infinite;
}

/* Fade In Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease-out;
}

/* Pulse Animation for Loading States */
@keyframes pulse {
    0%,
    100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Gradient Text Effect */
.gradient-text {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Scrollbar Styling */
.custom-scrollbar::-webkit-scrollbar {
    width: 8px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Focus Styles */
.focus-ring:focus {
    outline: none;
    ring: 4px;
    ring-color: rgb(167 139 250 / 0.3);
    border-color: #8b5cf6;
}

/* Character Count Color Transitions */
.char-count-normal {
    color: #6b7280;
    transition: color 0.3s ease;
}

.char-count-warning {
    color: #f59e0b;
    transition: color 0.3s ease;
}

.char-count-danger {
    color: #ef4444;
    transition: color 0.3s ease;
}

/* Modal Backdrop Blur */
.modal-backdrop {
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

/* Toast Animations */
.toast-enter {
    transform: translateY(100%) translateX(50%);
    opacity: 0;
}

.toast-enter-active {
    transform: translateY(0) translateX(0);
    opacity: 1;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.toast-exit {
    transform: translateY(0) translateX(0);
    opacity: 1;
}

.toast-exit-active {
    transform: translateY(100%) translateX(50%);
    opacity: 0;
    transition: all 0.3s ease-in-out;
}

/* Style Card Hover Effects */
.style-card-hover {
    transition: all 0.3s ease;
    will-change: transform, box-shadow;
}

.style-card-hover:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/* Button Loading State */
.btn-loading {
    position: relative;
    color: transparent;
}

.btn-loading::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 16px;
    margin: -8px 0 0 -8px;
    border: 2px solid #ffffff;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Responsive Grid Adjustments */
@media (max-width: 768px) {
    .category-tab {
        padding: 12px 16px;
        font-size: 14px;
    }

    .style-card {
        padding: 16px;
    }

    .toggle-switch {
        width: 36px;
        height: 20px;
    }

    .toggle-switch .toggle-dot {
        width: 16px;
        height: 16px;
    }

    input:checked + .toggle-switch .toggle-dot {
        transform: translateX(16px);
    }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .style-card {
        border-width: 2px;
        border-color: #000000;
    }

    .copy-btn {
        border: 2px solid #ffffff;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .toggle-switch,
    .toggle-switch .toggle-dot,
    .style-card,
    .copy-btn,
    .toast-enter-active,
    .toast-exit-active {
        transition: none;
    }

    .animate-spin,
    .animate-pulse,
    .fade-in {
        animation: none;
    }
}

/* Print Styles */
@media print {
    .sticky,
    .fixed,
    .copy-btn,
    .share-btn,
    button {
        display: none !important;
    }

    .style-card {
        break-inside: avoid;
        border: 1px solid #000000;
        margin-bottom: 20px;
    }

    .converted-text {
        font-size: 14px;
        line-height: 1.6;
    }
}

/* Dark Mode Support (if needed in future) */
@media (prefers-color-scheme: dark) {
    /* Currently disabled as per requirements */
}

/* Custom Utilities */
.border-b-3 {
    border-bottom-width: 3px;
}

.text-shadow-sm {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.transform-gpu {
    transform: translateZ(0);
}

/* Safari-specific fixes */
@supports (-webkit-appearance: none) {
    .toggle-switch {
        -webkit-appearance: none;
    }
}

/* Unicode Text Display */
.unicode-text {
    font-family: "Times New Roman", "Arial Unicode MS", "Segoe UI Symbol", "Noto Sans", "DejaVu Sans", sans-serif !important;
    font-feature-settings: "kern" 1, "liga" 1;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    word-break: break-word;
    overflow-wrap: break-word;
    hyphens: none;
    white-space: pre-wrap;
}
