/* Word Cards Container for Block View */
.word-cards-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

/* Individual Word Card */
.word-card {
    background: white;
    border: 1px solid #999999;
    border-radius: 8px;
    width: 180px;
    min-height: 250px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    overflow: hidden;
}

.word-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* Arabic Word Section */
.word-card .arabic {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: ivory;
    border-bottom: 1px solid #999999;
    padding: 8px;
    min-height: 55px;
}

.word-card .arabic .BtnArabic {
    border: none;
    color: darkgreen;
    background-color: transparent;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    padding: 4px 8px;
}

.word-card .arabic .BtnArabic:hover {
    background-color: rgba(0, 100, 0, 0.05);
    border-radius: 4px;
}

/* Transliteration Section */
.word-card .transliteration {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: lightcyan;
    border-bottom: 1px solid #999999;
    color: grey;
    padding: 8px;
    min-height: 45px;
    font-size: 14px;
    text-align: center;
}

/* Translation Section */
.word-card .translation {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: darkcyan;
    border-bottom: 1px solid #999999;
    color: white;
    padding: 8px;
    min-height: 50px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
}

/* Grammar Section */
.word-card .grammar {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f0f0f0;
    border-bottom: 1px solid #999999;
    color: #666;
    padding: 6px;
    min-height: 35px;
    font-size: 12px;
    text-align: center;
    font-style: italic;
}

/* Reference/Root Section */
.word-card .reference {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: lightyellow;
    padding: 8px;
    min-height: 50px;
    font-size: 12px;
    text-align: center;
}

.word-card .reference a.wfwRootA {
    color: green;
    text-decoration: none;
    font-size: 18px;
    font-weight: bold;
    padding: 2px 4px;
}

.word-card .reference a.wfwRootA:hover {
    text-decoration: underline;
    background-color: rgba(0, 128, 0, 0.05);
    border-radius: 3px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .word-cards-container {
        padding: 1rem;
        gap: 0.75rem;
    }
    
    .word-card {
        width: 160px;
        min-height: 230px;
    }
    
    .word-card .arabic .BtnArabic {
        font-size: 20px;
    }
    
    .word-card .reference a.wfwRootA {
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .word-cards-container {
        gap: 0.5rem;
    }
    
    .word-card {
        width: 140px;
        min-height: 210px;
    }
    
    .word-card .translation,
    .word-card .transliteration {
        font-size: 12px;
    }
}

/* Full Arabic Section (reuse from CV) */
#WfwBvTop {
    max-width: 1400px;
    margin: 2rem auto;
    padding: 0 2rem;
}

fieldset.cat1-a {
    text-align: right;
    font-size: 100%;
    color: black;
    background-color: #FFFFFF;
    border: 2px solid #1e3a8a;
    border-radius: 8px;
    padding: 1rem;
}

fieldset.cat1-a legend {
    color: #1e3a8a;
    font-weight: 600;
    padding: 0 0.5rem;
}

.BtnArabic {
    border: none;
    color: darkgreen;
    background-color: ivory;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 24px;
    font-weight: bold;
    margin: 4px 2px;
    cursor: pointer;
    padding: 8px 16px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.BtnArabic:hover {
    background-color: #fffff0;
}
