/* Flashcards (Kelime Kartları) Ödüllü ZefreNET Stilleri */

.flashcards-container {
    padding-top: 100px;
    min-height: 100vh;
    background: linear-gradient(135deg, #1a1708 0%, #2a2410 100%);
    position: relative;
}

/* Header Section */
.flashcards-header {
    padding: 3rem 0;
    text-align: center;
    color: white;
}

.flashcards-header h1 {
    font-family: 'Amiri', serif;
    font-size: 3.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
    color: var(--gold-primary, #d4a017);
    text-shadow: 0 4px 15px rgba(212, 160, 23, 0.3);
}

.subtitle {
    font-size: 1.2rem;
    color: rgba(255,255,255,0.7);
    margin-bottom: 2rem;
}

/* Stats Bar */
.stats-bar {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2.5rem;
    flex-wrap: wrap;
}

.stat-item {
    background: rgba(212, 160, 23, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 160, 23, 0.2);
    padding: 1rem 1.5rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 600;
    color: #fff;
    box-shadow: inset 0 0 20px rgba(0,0,0,0.5);
}

.stat-item i {
    font-size: 1.2rem;
    color: var(--gold-primary, #d4a017);
}

/* Quick Actions */
.quick-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn-action {
    padding: 0.8rem 1.8rem;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
    border: 1px solid transparent;
}

.btn-action:not(.secondary) {
    background: linear-gradient(135deg, var(--gold-primary, #d4a017), #b8860b);
    color: #111;
    box-shadow: 0 4px 15px rgba(212, 160, 23, 0.3);
}

.btn-action.secondary {
    background: rgba(0, 0, 0, 0.3);
    color: var(--gold-primary, #d4a017);
    border-color: rgba(212, 160, 23, 0.3);
}

.btn-action:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(212, 160, 23, 0.4);
}

.btn-action:not(.secondary):hover {
    background: linear-gradient(135deg, #e6b933, var(--gold-primary, #d4a017));
}

.btn-action.secondary:hover {
    background: rgba(212, 160, 23, 0.1);
    border-color: var(--gold-primary, #d4a017);
}

/* Study Mode */
.study-mode {
    padding: 2rem 0;
    min-height: calc(100vh - 120px);
    display: flex;
    align-items: center;
}

.study-progress {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    background: rgba(0,0,0,0.4);
    border: 1px solid rgba(212, 160, 23, 0.2);
    padding: 1rem 1.5rem;
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

.progress-info {
    color: var(--gold-primary, #d4a017);
    font-weight: 600;
    font-size: 1.1rem;
    min-width: 80px;
}

.progress-bar {
    flex: 1;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #b8860b, var(--gold-primary, #d4a017));
    border-radius: 4px;
    transition: width 0.5s ease;
}

.btn-exit {
    background: rgba(244, 67, 54, 0.15);
    color: #ff5252;
    border: 1px solid rgba(244, 67, 54, 0.3);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-exit:hover {
    background: #ff5252;
    color: #fff;
}

/* Flashcard Area */
.flashcard {
    width: 100%;
    max-width: 500px;
    height: 350px;
    margin: 0 auto 2.5rem;
    perspective: 1200px;
    cursor: pointer;
}

.flashcard-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
    border-radius: 16px;
}

.flashcard.flipped .flashcard-inner {
    transform: rotateY(180deg);
}

.flashcard-front,
.flashcard-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    background: rgba(20, 20, 25, 0.95);
    border: 1px solid rgba(212, 160, 23, 0.3);
    border-radius: 16px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5), inset 0 0 30px rgba(212, 160, 23, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
}

.flashcard-back {
    transform: rotateY(180deg);
    background: linear-gradient(135deg, rgba(20, 20, 25, 0.95), rgba(40, 35, 20, 0.95));
}

.card-content {
    text-align: center;
    width: 100%;
}

.card-content h2 {
    font-size: 2.5rem;
    color: #fff;
    margin-bottom: 1rem;
    font-weight: 600;
}

.flashcard-front .card-content h2 {
    font-family: 'Amiri', serif;
    font-size: 3.5rem;
    color: var(--gold-primary, #d4a017);
    direction: rtl;
}

.card-hint {
    color: rgba(255,255,255,0.4);
    font-style: italic;
    font-size: 0.9rem;
    position: absolute;
    bottom: 2rem;
    width: 100%;
    left: 0;
}

.pronunciation {
    color: var(--gold-primary, #d4a017);
    font-style: italic;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.category {
    background: rgba(212, 160, 23, 0.1);
    color: var(--gold-primary, #d4a017);
    border: 1px solid rgba(212, 160, 23, 0.3);
    padding: 0.3rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    margin-top: 10px;
    display: inline-block;
}

/* Audio Control */
.audio-control {
    text-align: center;
    margin-bottom: 2rem;
}

.btn-audio {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(212, 160, 23, 0.3);
    color: var(--gold-primary, #d4a017);
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-audio:hover {
    background: rgba(212, 160, 23, 0.1);
    border-color: var(--gold-primary, #d4a017);
}

/* Answer Buttons */
.answer-buttons {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.btn-answer {
    padding: 0.75rem 2rem;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1rem;
}

.btn-answer.difficult {
    background: rgba(244, 67, 54, 0.15);
    color: #ff5252;
    border-color: rgba(244, 67, 54, 0.4);
}

.btn-answer.good {
    background: rgba(212, 160, 23, 0.15);
    color: var(--gold-primary, #d4a017);
    border-color: rgba(212, 160, 23, 0.4);
}

.btn-answer.easy {
    background: rgba(76, 175, 80, 0.15);
    color: #4caf50;
    border-color: rgba(76, 175, 80, 0.4);
}

.btn-answer:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.btn-answer.difficult:hover { background: #ff5252; color: #fff; }
.btn-answer.good:hover { background: var(--gold-primary, #d4a017); color: #000; }
.btn-answer.easy:hover { background: #4caf50; color: #fff; }

/* Card Management */
.card-management {
    background: #0f1218;
    background-image: radial-gradient(circle at 100% 0%, rgba(212,160,23,0.05) 0%, transparent 50%);
    min-height: calc(100vh - 120px);
    padding: 3rem 0;
    border-top: 1px solid rgba(212, 160, 23, 0.1);
}

/* Filter Controls */
.filter-controls {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 3rem;
    padding: 1.5rem;
    background: rgba(20,20,25,0.7);
    border: 1px solid rgba(212,160,23,0.2);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.filter-group label {
    font-weight: 500;
    color: rgba(255,255,255,0.7);
    white-space: nowrap;
}

.filter-group select,
.filter-group input[type="text"] {
    padding: 0.6rem 1rem;
    background: rgba(0,0,0,0.5);
    border: 1px solid rgba(255,255,255,0.1);
    color: #fff;
    border-radius: 8px;
    font-size: 0.95rem;
    min-width: 140px;
    transition: all 0.3s;
}

.filter-group select:focus,
.filter-group input:focus {
    outline: none;
    border-color: var(--gold-primary, #d4a017);
    box-shadow: 0 0 10px rgba(212, 160, 23, 0.2);
}

.filter-group select option {
    background: #1a1f2e;
    color: #fff;
}

.btn-reset {
    background: rgba(244, 67, 54, 0.15);
    color: #ff5252;
    border: 1px solid rgba(244, 67, 54, 0.3);
    border-radius: 8px;
    width: 42px;
    height: 42px;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-reset:hover {
    background: #ff5252;
    color: white;
}

/* Cards Grid */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.card-item {
    background: rgba(20,20,25,0.8);
    border: 1px solid rgba(212,160,23,0.15);
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
    border-left: 4px solid var(--gold-primary, #d4a017);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.card-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
    border-color: rgba(212,160,23,0.4);
}

.card-item.new { border-left-color: #4caf50; }
.card-item.learning { border-left-color: #ff9800; }
.card-item.review { border-left-color: #ff5252; }
.card-item.mastered { border-left-color: #2196f3; }

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    padding-bottom: 0.75rem;
}

.card-state {
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
    color: #fff;
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(255,255,255,0.1) !important;
}

.card-item.new .card-state { color: #4caf50; border: 1px solid rgba(76,175,80,0.3); }
.card-item.learning .card-state { color: #ff9800; border: 1px solid rgba(255,152,0,0.3); }
.card-item.review .card-state { color: #ff5252; border: 1px solid rgba(255,82,82,0.3); }
.card-item.mastered .card-state { color: #2196f3; border: 1px solid rgba(33,150,243,0.3); }

.card-menu {
    background: none;
    border: none;
    color: rgba(255,255,255,0.4);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 5px;
    transition: all 0.3s;
}

.card-menu:hover {
    background: rgba(255,255,255,0.1);
    color: #fff;
}

.card-body h4 {
    font-family: 'Amiri', serif;
    font-size: 2rem;
    color: var(--gold-primary, #d4a017);
    margin-bottom: 0.5rem;
    direction: rtl;
    text-align: right;
}

.turkish-text {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.9);
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.card-footer {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.next-review {
    color: rgba(255,255,255,0.5);
    font-size: 0.85rem;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 5rem 2rem;
    background: rgba(20,20,25,0.5);
    border: 1px dashed rgba(212,160,23,0.3);
    border-radius: 16px;
}

.empty-state i {
    font-size: 4rem;
    color: rgba(212,160,23,0.2);
    margin-bottom: 1.5rem;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--gold-primary, #d4a017);
    font-family: 'Amiri', serif;
}

.empty-state p {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.6);
    margin-bottom: 2.5rem;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gold-primary, #d4a017), #b8860b);
    color: #111;
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary:hover {
    box-shadow: 0 5px 20px rgba(212, 160, 23, 0.4);
    transform: translateY(-2px);
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(5px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 2rem;
}

.modal-content {
    background: #1a1f2e;
    border: 1px solid rgba(212,160,23,0.3);
    border-radius: 16px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: modalSlideIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

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

.modal-header {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0,0,0,0.2);
}

.modal-header h3 {
    color: var(--gold-primary, #d4a017);
    margin: 0;
    font-size: 1.3rem;
    font-family: 'Amiri', serif;
}

.modal-close {
    background: rgba(255,255,255,0.05);
    color: rgba(255,255,255,0.6);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    width: 35px;
    height: 35px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.modal-close:hover {
    background: #ff5252;
    color: white;
    border-color: #ff5252;
}

.modal-body {
    padding: 2rem;
}

.modal-footer {
    padding: 1.5rem 2rem;
    border-top: 1px solid rgba(255,255,255,0.05);
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    background: rgba(0,0,0,0.2);
}

/* Form Styles */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: rgba(255,255,255,0.8);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.15);
    color: #fff;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--gold-primary, #d4a017);
    box-shadow: 0 0 10px rgba(212, 160, 23, 0.1);
}

.ottoman-input {
    font-family: 'Amiri', serif;
    direction: rtl;
    text-align: right;
    font-size: 1.3rem;
}

.btn-secondary {
    background: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.9);
    padding: 0.8rem 1.5rem;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.2);
}

/* Settings */
.settings-group {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 1rem 1.5rem;
    background: rgba(0,0,0,0.2);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 8px;
}

.settings-group label {
    font-weight: 500;
    color: rgba(255,255,255,0.9);
    margin-bottom: 0;
}

.settings-group select,
.settings-group input[type="checkbox"] {
    margin-left: 1rem;
    background: #0f1218;
    color: #fff;
    border-color: rgba(255,255,255,0.2);
}

/* Import Options */
.import-options {
    display: grid;
    gap: 1rem;
}

.import-btn {
    padding: 1rem;
    background: rgba(0,0,0,0.2);
    border: 1px solid rgba(212,160,23,0.2);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 1rem;
    font-weight: 600;
    color: rgba(255,255,255,0.8);
}

.import-btn:hover {
    background: rgba(212,160,23,0.1);
    color: var(--gold-primary, #d4a017);
    border-color: var(--gold-primary, #d4a017);
}

.import-btn i {
    font-size: 1.5rem;
    width: 30px;
    text-align: center;
    color: var(--gold-primary, #d4a017);
}

/* Notification */
.notification {
    position: fixed;
    top: 90px;
    right: 20px;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    color: white;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    z-index: 3000;
    transform: translateX(120%);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.4);
    font-weight: 500;
    border-left: 4px solid transparent;
}

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

.notification.success { background: #1a1f2e; border-left-color: #4caf50; border: 1px solid rgba(76,175,80,0.3); border-left: 4px solid #4caf50; }
.notification.error { background: #1a1f2e; border-left-color: #ff5252; border: 1px solid rgba(255,82,82,0.3); border-left: 4px solid #ff5252; }
.notification.info { background: #1a1f2e; border-left-color: var(--gold-primary, #d4a017); border: 1px solid rgba(212,160,23,0.3); border-left: 4px solid var(--gold-primary, #d4a017); }

/* Responsive Design */
@media (max-width: 768px) {
    .flashcards-header h1 {
        font-size: 2.2rem;
    }
    
    .stats-bar {
        gap: 1rem;
    }
    
    .stat-item {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }
    
    .quick-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .flashcard {
        width: 100%;
        height: 280px;
    }
    
    .card-content h2 {
        font-size: 2rem;
    }
    
    .flashcard-front .card-content h2 { font-size: 2.5rem; }
    
    .filter-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filter-group {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filter-group label {
        margin-bottom: 0.25rem;
    }
    
    .cards-grid {
        grid-template-columns: 1fr;
    }
    
    .answer-buttons {
        flex-direction: column;
    }
    
    .btn-answer {
        justify-content: center;
    }
    
    .modal {
        padding: 1rem;
    }
    
    .settings-group {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }
    
    .settings-group select,
    .settings-group input[type="checkbox"] {
        margin-left: 0;
        align-self: flex-start;
    }
}

/* Dark Mode */
@media (prefers-color-scheme: dark) {
    .card-management {
        background: #0f1218;
        background-image: radial-gradient(circle at 100% 0%, rgba(212,160,23,0.05) 0%, transparent 50%);
    }
    
    .filter-controls,
    .card-item,
    .modal-content {
        background: rgba(20,20,25,0.8);
        color: #e0e0e0;
    }
    
    .filter-controls input,
    .filter-controls select,
    .form-group input,
    .form-group select,
    .form-group textarea {
        background: rgba(0,0,0,0.5);
        color: #fff;
        border-color: rgba(255,255,255,0.1);
    }
    
    .empty-state {
        color: rgba(255,255,255,0.6);
    }
    
    .turkish-text {
        color: rgba(255,255,255,0.9);
    }
    
    .card-body h4 {
        color: var(--gold-primary, #d4a017);
    }
}

/* Ottoman Text Styling */
.ottoman-text {
    font-family: 'Amiri', serif;
    direction: rtl;
    text-align: right;
    line-height: 1.6;
}