/* Diacritic Remover Tool Styles */

/* Component Styles */
.toggle-bg {
    width: 2.75rem;
    height: 1.5rem;
    background-color: rgb(229 231 235);
    border-radius: 9999px;
    position: relative;
    transition: background-color 0.2s ease-in-out;
    cursor: pointer;
}

.toggle-bg.active,
input:checked + .toggle-bg {
    background-color: rgb(37 99 235);
}

.toggle-dot {
    position: absolute;
    left: 0.25rem;
    top: 0.25rem;
    background-color: white;
    width: 1rem;
    height: 1rem;
    border-radius: 9999px;
    transition: transform 0.2s ease-in-out;
}

.toggle-bg.active .toggle-dot,
input:checked + .toggle-bg .toggle-dot {
    transform: translateX(1.25rem);
}

/* Quick Action Buttons */
.quick-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 4.5rem;
    height: 3.5rem;
    border-radius: 0.5rem;
    border-width: 2px;
    transition: all 0.2s ease-in-out;
    cursor: pointer;
    font-weight: 600;
    padding: 0.25rem;
}

.quick-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.quick-btn:active {
    transform: translateY(0);
}

.quick-btn div {
    line-height: 1.1;
    white-space: nowrap;
}

.quick-btn-blue {
    border-color: rgb(191 219 254);
    background-color: rgb(239 246 255);
    color: rgb(29 78 216);
}

.quick-btn-blue:hover {
    border-color: rgb(147 197 253);
    background-color: rgb(219 234 254);
}

.quick-btn-red {
    border-color: rgb(254 202 202);
    background-color: rgb(254 242 242);
    color: rgb(185 28 28);
}

.quick-btn-red:hover {
    border-color: rgb(252 165 165);
    background-color: rgb(254 226 226);
}

.quick-btn-green {
    border-color: rgb(187 247 208);
    background-color: rgb(240 253 244);
    color: rgb(21 128 61);
}

.quick-btn-green:hover {
    border-color: rgb(134 239 172);
    background-color: rgb(220 252 231);
}

.quick-btn-purple {
    border-color: rgb(221 214 254);
    background-color: rgb(245 243 255);
    color: rgb(109 40 217);
}

.quick-btn-purple:hover {
    border-color: rgb(196 181 253);
    background-color: rgb(237 233 254);
}

/* Sample Text Buttons */
.sample-text-btn {
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    background-color: rgb(243 244 246);
    color: rgb(55 65 81);
    border-radius: 0.375rem;
    border: 1px solid rgb(229 231 235);
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}

.sample-text-btn:hover {
    background-color: rgb(229 231 235);
    border-color: rgb(209 213 219);
    transform: translateY(-1px);
}

.sample-text-btn:active {
    transform: translateY(0);
}

/* Method Selection Cards */
.method-option {
    cursor: pointer;
}

.method-card {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid rgb(229 231 235);
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    background-color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.method-card:hover {
    border-color: rgb(209 213 219);
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

.method-option input:checked + .method-card {
    border-color: rgb(59 130 246);
    background-color: rgb(239 246 255);
    color: rgb(30 64 175);
}

.method-option input:checked + .method-card:hover {
    border-color: rgb(37 99 235);
    background-color: rgb(219 234 254);
}

/* Export Buttons */
.export-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background-color: rgb(243 244 246);
    color: rgb(55 65 81);
    border-radius: 0.5rem;
    border: 1px solid rgb(229 231 235);
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    font-weight: 500;
}

.export-btn:hover {
    background-color: rgb(229 231 235);
    border-color: rgb(209 213 219);
    transform: translateY(-1px);
}

.export-btn:active {
    transform: translateY(0);
}

.export-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

/* Statistics Items */
.stat-item {
    background-color: rgb(249 250 251);
    border-radius: 0.5rem;
    padding: 0.75rem;
    text-align: center;
    border: 1px solid rgb(229 231 235);
    transition: all 0.2s ease-in-out;
}

.stat-item:hover {
    background-color: rgb(243 244 246);
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: rgb(17 24 39);
    line-height: 1.2;
}

.stat-label {
    font-size: 0.875rem;
    color: rgb(75 85 99);
    margin-top: 0.25rem;
}

/* Enhanced Input/Output Styling */
textarea:focus {
    outline: none;
    ring: 2px;
    ring-color: rgb(59 130 246);
    border-color: transparent;
}

/* Button Enhancements */
button:focus {
    outline: 2px solid transparent;
    outline-offset: 2px;
    ring: 2px;
    ring-color: rgb(59 130 246);
    ring-offset: 2px;
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Modal Enhancements */
.modal-backdrop {
    backdrop-filter: blur(4px);
}

/* Loading Spinner */
.loading-spinner {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .quick-btn {
        width: 4rem;
        height: 3rem;
        font-size: 0.75rem;
    }

    .method-card {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
    }

    .export-btn {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
    }

    .stat-value {
        font-size: 1.25rem;
    }

    .stat-label {
        font-size: 0.75rem;
    }
}

@media (max-width: 640px) {
    .quick-btn {
        width: 3.5rem;
        height: 2.75rem;
        font-size: 0.7rem;
    }

    .quick-btn div {
        font-size: 0.65rem;
    }

    .sample-text-btn {
        font-size: 0.7rem;
        padding: 0.2rem 0.5rem;
    }

    .method-card {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
}

/* Animation Enhancements */
.fade-in {
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.slide-in {
    animation: slideIn 0.3s ease-in-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Progress Indicators */
.progress-bar {
    height: 0.25rem;
    background-color: rgb(229 231 235);
    border-radius: 9999px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background-color: rgb(59 130 246);
    border-radius: 9999px;
    transition: width 0.3s ease-in-out;
}

/* Tooltip Styles */
.tooltip {
    position: relative;
}

.tooltip::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.5rem;
    background-color: rgb(17 24 39);
    color: white;
    font-size: 0.75rem;
    border-radius: 0.375rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease-in-out;
    z-index: 1000;
}

.tooltip:hover::before {
    opacity: 1;
}

/* Accessibility Enhancements */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .method-card,
    .export-btn,
    .sample-text-btn {
        border-width: 2px;
        border-color: currentColor;
    }

    .stat-item {
        border-width: 2px;
    }
}

/* Dark Mode Support (if needed) */
@media (prefers-color-scheme: dark) {
    /* Dark mode styles would go here if needed */
}

/* Print Styles */
@media print {
    .quick-btn,
    .export-btn,
    .sample-text-btn,
    button {
        display: none;
    }

    .bg-gradient-to-r {
        background: white !important;
        border: 1px solid #ccc !important;
    }
}
