/* Sözlük Sayfası Stilleri
 *
 * NOT: Site geneli LIGHT (krem) + gold tema (concept-b-override.css). Eski mor/indigo
 *   palet (#667eea/#764ba2/#1a237e) site geneliyle uyumsuzdu; gold/krem'e taşındı.
 *   --white token'ı koyu kahve (#2C2416) → ana metinler koyu. Beyaz yazı yalnızca
 *   gold gradient zeminlerde (modal-header vb.) kullanılır.
 */

.dictionary-container {
    padding-top: 80px;
    min-height: 100vh;
    background: transparent; /* body krem zemini görünsün */
}

/* Search Section */
.search-section {
    background: var(--glass-white-strong);
    padding: 3rem 0;
    margin-bottom: 2rem;
    box-shadow: 0 2px 10px rgba(44, 36, 22, 0.08);
}

.search-section h1 {
    text-align: center;
    font-size: 2.5rem;
    color: var(--white);
    margin-bottom: 0.5rem;
}

.subtitle {
    text-align: center;
    color: #6B5D4C;
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

/* Search Bar */
.search-bar {
    max-width: 600px;
    margin: 0 auto 2rem;
    position: relative;
    display: flex;
    background: var(--glass-white-strong);
    border: 2px solid var(--gold-primary);
    border-radius: 50px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(212, 168, 67, 0.18);
}

.search-bar input {
    flex: 1;
    padding: 1rem 1.5rem;
    border: none;
    outline: none;
    font-size: 1.1rem;
    background: transparent;
    color: var(--white);
}

.search-bar button {
    padding: 1rem 1.5rem;
    background: var(--gold-primary);
    color: #2C2416;
    border: none;
    cursor: pointer;
    transition: background 0.3s;
}

.search-bar button:hover {
    background: var(--gold-dark);
    color: #FBF8F0;
}

/* Filter Options */
.filter-options {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.filter-options select {
    padding: 0.5rem 1rem;
    border: 2px solid var(--glass-border);
    border-radius: 25px;
    background: var(--glass-white-strong);
    color: var(--white);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s;
}

.filter-options select:focus {
    outline: none;
    border-color: var(--gold-primary);
}

.btn-reset {
    padding: 0.5rem 1rem;
    background: #B91C1C;
    color: #FBF8F0;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: background 0.3s;
    font-size: 0.9rem;
}

.btn-reset:hover {
    background: #991B1B;
}

/* Search Suggestions */
.search-suggestions {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
    background: var(--glass-white-strong);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(44, 36, 22, 0.10);
    z-index: 1000;
    display: none;
}

.suggestion-item {
    display: flex;
    justify-content: space-between;
    padding: 1rem;
    border-bottom: 1px solid var(--glass-border);
    cursor: pointer;
    transition: background 0.3s;
}

.suggestion-item:hover {
    background: rgba(212, 168, 67, 0.10);
}

.suggestion-item:last-child {
    border-bottom: none;
}

.suggestion-item .ottoman {
    font-family: 'Amiri', serif;
    font-size: 1.1rem;
    color: var(--gold-dark);
    font-weight: 600;
}

.suggestion-item .turkish {
    color: #6B5D4C;
}

/* Results Section */
.results-section {
    padding: 0 0 3rem;
}

.results-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding: 1rem;
    background: var(--glass-white);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(44, 36, 22, 0.05);
}

.results-info span {
    color: #4A463B;
    font-weight: 600;
}

.view-options {
    display: flex;
    gap: 0.5rem;
}

.view-btn {
    padding: 0.5rem 1rem;
    background: var(--glass-white);
    border: 2px solid var(--glass-border);
    color: #4A463B;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.view-btn.active {
    background: var(--gold-primary);
    border-color: var(--gold-primary);
    color: #2C2416;
}

.view-btn:hover {
    background: rgba(212, 168, 67, 0.14);
}

.view-btn.active:hover {
    background: var(--gold-dark);
    color: #FBF8F0;
}

/* Word Grid */
.word-grid {
    display: grid;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.word-grid.grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.word-grid.list {
    grid-template-columns: 1fr;
}

/* Word Card */
.word-card {
    background: var(--glass-white-strong);
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: 0 2px 10px rgba(44, 36, 22, 0.05);
    cursor: pointer;
    transition: all 0.3s;
    border: 2px solid var(--glass-border);
}

.word-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(44, 36, 22, 0.12);
    border-color: var(--gold-primary);
}

.word-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.word-card-header h3 {
    font-family: 'Amiri', serif;
    font-size: 1.8rem;
    color: var(--gold-dark);
    margin: 0;
    font-weight: 700;
    line-height: 1.2;
}

.word-badges {
    display: flex;
    gap: 0.5rem;
}

.badge {
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #FBF8F0;
}

.badge.difficulty {
    /* Renk JavaScript'te dinamik olarak ayarlanır */
}

.badge.başlangıç {
    background: #059669;
}

.badge.orta {
    background: #B47814;
}

.badge.ileri {
    background: #B91C1C;
}

.word-card-body {
    margin-bottom: 1rem;
}

.turkish-meaning {
    font-size: 1.2rem;
    color: var(--white);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.pronunciation {
    font-style: italic;
    color: #6B5D4C;
    font-size: 0.95rem;
}

.word-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: #8C8471;
}

.category,
.frequency {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Loading Spinner */
.loading-spinner {
    text-align: center;
    padding: 3rem;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(212, 168, 67, 0.2);
    border-top: 4px solid var(--gold-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

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

/* No Results */
.no-results {
    text-align: center;
    padding: 3rem;
    color: #6B5D4C;
}

.no-results i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #A89880;
}

.no-results h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--white);
}

/* Error Message */
.error-message {
    text-align: center;
    padding: 3rem;
    color: #B91C1C;
}

.error-message i {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* Word Modal */
.word-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(44, 36, 22, 0.75);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 2rem;
}

.modal-content {
    background: #FBF8F0;
    border-radius: 20px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: modalSlideIn 0.3s ease;
}

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

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: #B91C1C;
    color: #FBF8F0;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    font-size: 1.2rem;
    z-index: 1;
}

.modal-header {
    background: linear-gradient(135deg, var(--gold-primary) 0%, var(--gold-dark) 100%);
    color: #FBF8F0;
    padding: 2rem;
    border-radius: 20px 20px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    font-family: 'Amiri', serif;
    font-size: 2.5rem;
    margin: 0;
    font-weight: 700;
}

.btn-audio {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: #FBF8F0;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s;
}

.btn-audio:hover {
    background: rgba(255, 255, 255, 0.3);
}

.modal-body {
    padding: 2rem;
}

.word-info {
    display: grid;
    gap: 1rem;
    margin-bottom: 2rem;
}

.info-item {
    display: flex;
    align-items: center;
    padding: 0.75rem;
    background: rgba(212, 168, 67, 0.08);
    border-radius: 10px;
}

.info-item label {
    font-weight: 600;
    color: #4A463B;
    min-width: 80px;
    margin-right: 1rem;
}

.info-item span {
    color: #6B5D4C;
}

.example-section {
    background: rgba(212, 168, 67, 0.10);
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    border-left: 4px solid var(--gold-primary);
}

.example-section h4 {
    color: var(--gold-dark);
    margin-bottom: 1rem;
}

.example-section .ottoman-text {
    font-family: 'Amiri', serif;
    font-size: 1.2rem;
    color: var(--white);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.example-section .translation {
    color: #6B5D4C;
    font-style: italic;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-action {
    padding: 0.75rem 1.5rem;
    background: var(--gold-primary);
    color: #2C2416;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-action:hover {
    background: var(--gold-dark);
    color: #FBF8F0;
    transform: translateY(-2px);
}

/* Notification */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 1rem 1.5rem;
    border-radius: 10px;
    color: #FBF8F0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    z-index: 3000;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    box-shadow: 0 5px 15px rgba(44, 36, 22, 0.2);
}

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

.notification.success {
    background: #059669;
}

.notification.error {
    background: #B91C1C;
}

.notification.info {
    background: var(--gold-dark);
}

/* Responsive Design */
@media (max-width: 768px) {
    .search-section {
        padding: 2rem 0;
    }

    .search-section h1 {
        font-size: 2rem;
    }

    .search-bar {
        margin: 0 1rem 2rem;
    }

    .filter-options {
        padding: 0 1rem;
    }

    .filter-options select {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }

    .word-grid.grid {
        grid-template-columns: 1fr;
    }

    .word-card-header h3 {
        font-size: 1.5rem;
    }

    .results-info {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .modal-content {
        margin: 1rem;
        max-height: calc(100vh - 2rem);
    }

    .modal-header {
        padding: 1.5rem;
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .modal-header h2 {
        font-size: 2rem;
    }

    .modal-actions {
        flex-direction: column;
    }

    .btn-action {
        justify-content: center;
    }
}

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

/* List View Specific Styles */
.word-grid.list .word-card {
    display: flex;
    align-items: center;
    gap: 2rem;
    padding: 1rem 1.5rem;
}

.word-grid.list .word-card-header {
    flex: 1;
    margin-bottom: 0;
}

.word-grid.list .word-card-body {
    flex: 2;
    margin-bottom: 0;
}

.word-grid.list .word-card-footer {
    flex: 1;
}

.word-grid.list .word-card-header h3 {
    font-size: 1.5rem;
}

@media (max-width: 768px) {
    .word-grid.list .word-card {
        flex-direction: column;
        gap: 1rem;
    }
}
