/* =========================================
   VOCALIBRARY
========================================= */

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;

    font-family: Arial, Helvetica, sans-serif;

    background: #f5f9ff;
    color: #1e293b;
}


/* =========================================
   HEADER
========================================= */

.vocab-header {
    width: 100%;

    padding: 22px 40px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    background: #2563eb;

    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.10);
}


/* =========================================
   HEADER TITLE
========================================= */

.vocab-header .title-area {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.vocab-header .title-area h1 {
    margin: 0;

    color: #ffffff;

    font-size: 30px;
    font-weight: 700;
}

.vocab-header .title-area p {
    margin: 0;

    color: #dbeafe;

    font-size: 14px;
    font-weight: 500;
}


/* =========================================
   HEADER NAVIGATION
========================================= */

.vocab-header .unit-tabs {
    display: flex;
    align-items: center;
    gap: 12px;
}

.vocab-header .unit-tabs a {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 100px;
    height: 42px;
    box-sizing: border-box;

    padding: 0;

    border-radius: 12px;

    color: white;

    background: linear-gradient(
        135deg,
        #2563eb,
        #38bdf8
    );

    text-decoration: none;

    font-size: 14px;
    font-weight: 600;

    box-shadow:
        0 3px 8px rgba(0, 0, 0, 0.12);

    transition: all 0.2s ease;
}

.vocab-header .unit-tabs a:hover {
    transform: translateY(-3px);

    box-shadow:
        0 8px 18px rgba(0, 0, 0, 0.25);
}


/* BACK BUTTON */

.vocab-header .unit-tabs .back-btn {
    color: white;

    background: linear-gradient(
        135deg,
        #2563eb,
        #38bdf8
    );
}

.vocab-header .unit-tabs .back-btn:hover {
    transform: translateY(-3px);

    box-shadow:
    0 8px 18px rgba(0,0,0,0.25);
}

.vocab-header .unit-tabs .back-btn i {
    margin-right: 7px;
}


/* =========================================
   MAIN CONTENT
========================================= */

.vocabulary-page {
    width: 100%;
    max-width: 1200px;

    margin: 0 auto;

    padding: 35px 25px 50px;
}


/* =========================================
   INTRO
========================================= */

.vocabulary-intro {
    text-align: center;

    margin-bottom: 30px;
}

.vocabulary-intro h2 {
    margin: 0 0 10px;

    color: #1e3a8a;

    font-size: 28px;
    font-weight: 700;
}

.vocabulary-intro p {
    margin: 0;

    color: #64748b;

    font-size: 16px;
}


/* =========================================
   VOCABULARY CONTAINER
========================================= */

.vocabulary-container {
    width: 100%;

    display: flex;
    justify-content: center;
    align-items: center;

    margin-bottom: 30px;
}


/* JavaScript will place the word card here */

#vocabularyList {
    width: 100%;

    display: flex;
    justify-content: center;
}


/* =========================================
   WORD CARD
========================================= */

.word-card {
    width: 100%;
    max-width: 650px;

    padding: 40px 35px;

    background: #ffffff;

    border: 1px solid #dbeafe;

    border-radius: 20px;

    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.10);

    text-align: center;
}


/* =========================================
   WORD
========================================= */

.word-card h3 {
    margin: 0 0 12px;

    color: #2563eb;

    font-size: 38px;
    font-weight: 700;
}

.word-card .meaning {
    margin: 0 0 20px;

    color: #334155;

    font-size: 22px;
    font-weight: 600;
}


/* =========================================
   EXAMPLE
========================================= */

.word-card .example {
    margin: 20px auto 0;

    padding: 15px 18px;

    max-width: 500px;

    background: #f0f7ff;

    border-left: 4px solid #2563eb;

    border-radius: 10px;

    color: #475569;

    font-size: 15px;
    line-height: 1.6;
}


/* =========================================
   AUDIO BUTTON
========================================= */

.audio-btn {
    border: none;

    width: 48px;
    height: 48px;

    border-radius: 50%;

    background: #2563eb;

    color: #ffffff;

    font-size: 20px;

    cursor: pointer;

    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);

    transition: all 0.2s ease;
}

.audio-btn:hover {
    background: #1d4ed8;

    transform: scale(1.05);
}


/* =========================================
   VOCABULARY CONTROLS
========================================= */

.vocabulary-controls {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 20px;

    margin-top: 25px;
}


/* Previous / Next */

.vocabulary-controls button {
    border: none;

    min-width: 130px;

    padding: 12px 22px;

    border-radius: 12px;

    background: #2563eb;

    color: #ffffff;

    font-size: 15px;
    font-weight: 600;

    cursor: pointer;

    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.20);

    transition: all 0.2s ease;
}

.vocabulary-controls button:hover {
    background: #1d4ed8;

    transform: translateY(-2px);
}

.vocabulary-controls button:disabled {
    background: #cbd5e1;

    color: #64748b;

    cursor: not-allowed;

    box-shadow: none;

    transform: none;
}


/* Word counter */

#wordCounter {
    min-width: 60px;

    text-align: center;

    color: #334155;

    font-size: 15px;
    font-weight: 700;
}


/* =========================================
   MOBILE
========================================= */

@media (max-width: 768px) {

    .vocab-header {
        padding: 20px 16px;

        flex-direction: column;

        gap: 18px;

        text-align: center;
    }


    .vocab-header .title-area {
        align-items: center;
    }


    .vocab-header .title-area h1 {
        font-size: 25px;
    }


    .vocab-header .title-area p {
        font-size: 13px;
    }


    .vocab-header .unit-tabs {
        width: 100%;

        justify-content: center;

        gap: 8px;
    }


    .vocab-header .unit-tabs a {
        min-height: 38px;

        padding: 0 12px;

        font-size: 13px;
    }


    .vocabulary-page {
        padding: 25px 15px 40px;
    }


    .vocabulary-intro {
        margin-bottom: 25px;
    }


    .vocabulary-intro h2 {
        font-size: 24px;
    }


    .vocabulary-intro p {
        font-size: 14px;

        line-height: 1.5;
    }


    .word-card {
        padding: 30px 20px;

        border-radius: 18px;
    }


    .word-card h3 {
        font-size: 32px;
    }


    .word-card .meaning {
        font-size: 19px;
    }


    .word-card .example {
        font-size: 14px;
    }


    .vocabulary-controls {
        gap: 10px;
    }


    .vocabulary-controls button {
        min-width: 110px;

        padding: 11px 15px;

        font-size: 14px;
    }

}


/* =========================================
   SMALL MOBILE
========================================= */

@media (max-width: 480px) {

    .vocab-header .unit-tabs {
        gap: 6px;
    }


    .vocab-header .unit-tabs a {
        padding: 0 9px;

        font-size: 12px;
    }


    .vocabulary-intro h2 {
        font-size: 22px;
    }


    .word-card h3 {
        font-size: 29px;
    }


    .vocabulary-controls {
        gap: 7px;
    }


    .vocabulary-controls button {
        min-width: 100px;

        padding: 10px 12px;

        font-size: 13px;
    }

}

/* =========================================
   VOCABULARY WORD CARD
========================================= */

.word-card {
    position: relative;

    width: 100%;
    max-width: 700px;

    padding: 45px 40px 35px;

    background: #ffffff;

    border: 1px solid #dbeafe;
    border-radius: 24px;

    box-shadow:
        0 10px 30px rgba(37, 99, 235, 0.10);

    text-align: center;

    overflow: hidden;
}


/* Top line */

.word-card::before {
    content: "";

    position: absolute;

    top: 0;
    left: 0;

    width: 100%;
    height: 6px;

    background: #2563eb;
}


/* Word number */

.word-number {
    margin-bottom: 12px;

    color: #64748b;

    font-size: 13px;
    font-weight: 600;

    text-transform: uppercase;
    letter-spacing: 1px;
}


/* English word */

.word-card h3 {
    margin: 0;

    color: #1e3a8a;

    font-size: 42px;
    font-weight: 700;

    line-height: 1.2;
}


/* Word type */

.word-type {
    display: inline-block;

    margin-top: 12px;
    padding: 5px 12px;

    border-radius: 20px;

    background: #eff6ff;

    color: #2563eb;

    font-size: 13px;
    font-weight: 600;
}


/* Turkish meaning */

.word-card .meaning {
    margin: 20px 0 0;

    color: #334155;

    font-size: 23px;
    font-weight: 600;
}


/* Audio */

.audio-btn {
    display: flex;

    align-items: center;
    justify-content: center;

    width: 52px;
    height: 52px;

    margin: 22px auto;

    border: none;
    border-radius: 50%;

    background: #2563eb;

    color: #ffffff;

    font-size: 21px;

    cursor: pointer;

    box-shadow:
        0 5px 12px rgba(37, 99, 235, 0.25);

    transition: all 0.2s ease;
}

.audio-btn:hover {
    background: #1d4ed8;

    transform: scale(1.06);
}


/* =========================================
   EXAMPLE SENTENCE
   ========================================= */

.example-box {
    background: #eff6ff;
    border-radius: 15px;
    padding: 14px 16px;
    margin-top: 12px;
    box-sizing: border-box;
}

.example-label {
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 5px;
}

.example {
    margin: 0;
    padding: 12px 16px;
    background: transparent;
    border-left: 4px solid #2563eb;
    border-right: 4px solid #2563eb;
    border-radius: 10px;
    font-size: 14px;
    line-height: 1.5;
    color: #334155;
}

.example-tr {
    margin: 5px 0 0;
    padding: 0;
    background: transparent;
    border: none;
    font-size: 12px;
    line-height: 1.4;
    color: #64748b;
    font-style: italic;
}


/* =========================================
   WORD ACTIONS
========================================= */

.word-actions {
    display: flex;

    justify-content: center;

    gap: 12px;

    margin-top: 25px;
}

.word-actions button {
    border: none;

    padding: 11px 18px;

    border-radius: 11px;

    font-size: 14px;
    font-weight: 600;

    cursor: pointer;

    transition: all 0.2s ease;
}


/* I know */

.know-word {
    background: #dcfce7;

    color: #166534;
}

.know-word:hover {
    background: #bbf7d0;

    transform: translateY(-2px);
}


/* Review */

.review-word {
    background: #fef3c7;

    color: #92400e;
}

.review-word:hover {
    background: #fde68a;

    transform: translateY(-2px);
}


/* =========================================
   MOBILE WORD CARD
========================================= */

@media (max-width: 768px) {

    .word-card {
        max-width: 100%;

        padding: 38px 20px 28px;

        border-radius: 20px;
    }

    .word-card h3 {
        font-size: 34px;
    }

    .word-card .meaning {
        font-size: 20px;
    }

    .word-actions {
        flex-direction: column;

        align-items: stretch;
    }

    .word-actions button {
        width: 100%;
    }

}

/* =========================================
   VOCABULARY PROGRESS
========================================= */

.vocabulary-progress {
    width: 100%;
    max-width: 700px;

    margin: 0 auto 25px;

    padding: 18px 20px;

    background: #ffffff;

    border: 1px solid #dbeafe;

    border-radius: 16px;

    box-shadow: 0 5px 15px rgba(37, 99, 235, 0.07);
}


.progress-header {
    display: flex;

    align-items: center;
    justify-content: space-between;

    margin-bottom: 10px;

    color: #334155;

    font-size: 14px;
    font-weight: 600;
}


.progress-header strong {
    color: #2563eb;
}


.progress-bar {
    width: 100%;
    height: 10px;

    overflow: hidden;

    background: #e2e8f0;

    border-radius: 20px;
}


.progress-fill {
    width: 0%;
    height: 100%;

    background: #2563eb;

    border-radius: 20px;

    transition: width 0.3s ease;
}


.progress-info {
    display: flex;

    justify-content: space-between;

    margin-top: 9px;

    color: #64748b;

    font-size: 12px;
}


@media (max-width: 768px) {

    .vocabulary-progress {
        margin-bottom: 20px;

        padding: 15px;
    }

    .progress-header {
        font-size: 13px;
    }

    .progress-info {
        font-size: 11px;
    }

    }

    @media (max-width: 600px) {

    .vocab-header {
        width: 100%;
        box-sizing: border-box;
        padding: 14px 12px 18px;
    }

    .vocab-header .title-area {
        width: 100%;
        text-align: center;
        margin-bottom: 10px;
    }

    .vocab-header .title-area h1 {
        font-size: 25px;
        margin: 0;
    }

    .vocab-header .unit-tabs {
        width: 100%;
        display: flex;
        flex-direction: row;
        justify-content: stretch;
        align-items: center;

        gap: 5px;

        margin: 0;
        padding: 0;

        box-sizing: border-box;
    }

    .vocab-header .unit-tabs a {
        flex: 1 1 0;

        width: 0;
        min-width: 0;
        max-width: none;

        height: 40px;
        min-height: 40px;

        padding: 0 4px ;
        margin: 0;

        display: flex;
        align-items: center;
        justify-content: center;

        box-sizing: border-box;

        font-size: 12px;
        white-space: nowrap;

        border-radius: 11px;
    }

}







/* =========================================
   CURRENT WORD
========================================= */

.current-word-info {
    margin-top: 0px;

    text-align: center;

    color: #64748b;

    font-size: 13px;
    font-weight: 600;
}

.current-word-info strong {
    color: #2563eb;

    margin-left: 0px;
}

#progressText {
    display: none;
}


.vocab-header .unit-tabs {
    display: flex;
    align-items: center;
    gap: 12px;
}

.vocab-header .unit-tabs a {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 110px !important;
    min-width: 110px !important;
    height: 42px !important;
    min-height: 42px !important;

    box-sizing: border-box;
    padding: 0 !important;
    margin: 0 !important;

    border: none !important;
    border-radius: 12px;

    color: white !important;
    background: linear-gradient(
        135deg,
        #2563eb,
        #38bdf8
    ) !important;

    text-decoration: none;

    font-size: 14px;
    font-weight: 600;

    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);

    transition: all 0.2s ease;
}

.vocab-header .unit-tabs a:hover {
    transform: translateY(-3px);

    box-shadow:
        0 8px 18px rgba(0, 0, 0, 0.25);
}

/* VocaLibrary'nin özel back-btn stilini etkisizleştir */
.vocab-header .unit-tabs a.back-btn {
    width: 110px !important;
    min-width: 110px !important;
    height: 42px !important;

    background: linear-gradient(
        135deg,
        #2563eb,
        #38bdf8
    ) !important;

    color: white !important;
    border: none !important;
}

/* =========================================
   👁 SHOW MEANING BUTTON
   ========================================= */

.show-meaning-btn {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 100%;
    max-width: 240px;
    min-height: 44px;

    margin: 20px auto;

    padding: 0 20px;

    border: none;
    border-radius: 12px;

    background: linear-gradient(
        135deg,
        #2563eb,
        #38bdf8
    );

    color: white;

    font-size: 14px;
    font-weight: 600;

    cursor: pointer;

    box-shadow:
        0 4px 10px rgba(37, 99, 235, 0.20);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}


/* Hover */

.show-meaning-btn:hover {

    transform: translateY(-2px);

    box-shadow:
        0 7px 16px rgba(37, 99, 235, 0.28);
}


/* Click */

.show-meaning-btn:active {

    transform: translateY(0);

    box-shadow:
        0 3px 7px rgba(37, 99, 235, 0.20);
}

/* =========================================
   MEANING SECTION
   ========================================= */

#meaningSection {
    text-align: center;
    animation: meaningReveal 0.25s ease;
}

#meaningSection .meaning {
    margin: 16px 0;
    font-size: 22px;
    font-weight: 700;
}


/* =========================================
   EXAMPLE BOX
   ========================================= */

#meaningSection .example-box {
    margin-top: 18px;
}


/* Türkçe örnek */

#meaningSection .example-tr {
    margin-top: 10px;
    padding-top: 10px;

    border-top: 1px solid #dbeafe;

    font-size: 14px;
    color: #64748b;
    font-style: italic;
}


/* Açılma animasyonu */

@keyframes meaningReveal {

    from {
        opacity: 0;
        transform: translateY(6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }

}

@media (max-width: 600px) {

    .show-meaning-btn {
        max-width: 220px;
        min-height: 42px;
        font-size: 13px;
    }

    #meaningSection .meaning {
        font-size: 20px;
    }

}