:root {
    --primary-blue: #3b71ca;
}
body { 
    background-color: #f0f2f5; 
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}
.card { 
    border-radius: 24px; 
    border: none; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    overflow: hidden;
}
.header-box { 
    background: linear-gradient(135deg, #4b84e3, #2a5bb1);
    color: white; 
    padding: 20px 25px; 
}
.header-box h3 { font-weight: 700; margin-bottom: 10px; }
.header-box p { opacity: 0.9; font-size: 0.95rem; }

.form-control-lg {
    border-radius: 12px;
    padding: 15px;
    border: 2px solid #eef0f2;
    font-size: 2rem;
    font-weight: 500;
}
.form-control-lg:focus {
    border-color: var(--primary-blue);
    box-shadow: none;
}
.result-display {
    background-color: #f8faff;
    border-radius: 16px;
    padding: 25px;
    margin: 20px 0;
    position: relative;
}
.transcription-text {
    color: #4881e0;
    font-weight: 600;
    letter-spacing: 0.5px;
}
.copy-box {
    background: white;
    border: 1px solid #eef0f2;
    border-radius: 12px;
    padding: 12px 20px;
}
#textResult {
    word-wrap: break-word;
    max-width: 100%;
}

/* Квадратные карточки шпаргалки */
.cheat-card-square {
    background-color: #f8faff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    aspect-ratio: 1 / 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 10px;
    position: relative;
    cursor: pointer;
}
.cheat-card-square:hover {
    background: #3a71ca29;
    border: 1px solid #3a71ca;
}

.cheat-card-square .cheat-num {
    color: #3b71ca;
    font-size: 2.6rem;
    font-weight: 800;
    line-height: 1;
}

.cheat-card-square .cheat-txt {
    color: #475569;
    font-size: 1.5rem;
    font-weight: 600;
}
.cheat-trans {
    color: #3b71ca; /* Тот же красный, что в основном блоке */
    font-size: 0.85rem;
    font-weight: 600;
    margin-top: 4px;
}

@media (max-width: 576px) {
    .cheat-trans { font-size: 0.65rem; }
}
/* Адаптив для мобилок, чтобы квадраты были ровными */
@media (max-width: 576px) {
    .cheat-card-square .cheat-num { font-size: 1.3rem; }
    .cheat-card-square .cheat-txt { font-size: 0.75rem; }
    .cheat-card-square { border-radius: 15px; }
}
        /* Контейнер для карточек-цифр в результате */
.digits-result-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-top: 15px;
}

/* Делаем карточки в результате чуть компактнее, чем в шпаргалке */
.digits-result-wrapper .cheat-card-square {
    min-width: 90px;
    flex: 0 0 auto;
    cursor: default; /* В результате по ним кликать не нужно */
}


.click-to-audio {
    position: absolute;
    bottom: 10px;
    right: 10px;
    width: 8%;
    color: #3b71ca;
    cursor: pointer;
}
.click-to-audio:hover {
    color: #2b569e;
}

.click-to-audio-cheat {
    position: absolute;
    bottom: 5px;
    right: 5px;
    width: 15%;
    color: #3b71ca;
}
.click-to-audio-phrase {
    position: absolute;
    bottom: 5px;
    right: 5px;
    width: 10%;
    color: #3b71ca;
}

.text-blue {
    color: #3b71ca;
}

.phrase-card {
    background-color: #f8faff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
}
.phrase-card:hover {
    background: #3a71ca29;
    border: 1px solid #3a71ca;
}