/* EA ECHOing Engine — Front-end Styles */

.eaecho-exercise {
    max-width: 780px;
    margin: 0 auto;
    padding: 24px 16px;
    font-family: inherit;
}

.eaecho-exercise-title {
    font-size: 26px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 8px;
}

.eaecho-description {
    font-size: 15px;
    color: #555;
    margin: 0 0 20px;
    line-height: 1.6;
}

/* Progress */
.eaecho-progress-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.eaecho-progress-label {
    font-size: 13px;
    color: #666;
    white-space: nowrap;
}

.eaecho-progress-bar {
    flex: 1;
    background: #e8ecf0;
    border-radius: 99px;
    height: 5px;
    overflow: hidden;
}

.eaecho-progress-fill {
    height: 5px;
    background: #185FA5;
    border-radius: 99px;
    transition: width .4s ease;
    width: 0%;
}

/* Phrase Cards */
.eaecho-card {
    border: 1px solid #dde2e8;
    border-radius: 10px;
    padding: 16px 18px;
    margin-bottom: 12px;
    background: #fff;
    transition: border-color .2s;
}

.eaecho-card.is-done {
    border-color: #1D9E75;
}

.eaecho-card-num {
    font-size: 11px;
    color: #999;
    text-transform: uppercase;
    letter-spacing: .05em;
    margin-bottom: 6px;
}

.eaecho-phrase-text {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 14px;
    line-height: 1.45;
    transition: opacity .2s;
}

.eaecho-phrase-text.is-hidden {
    opacity: 0;
    user-select: none;
    pointer-events: none;
}

/* Audio rows */
.eaecho-audio-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.eaecho-audio-label {
    font-size: 12px;
    font-weight: 700;
    color: #185FA5;
    min-width: 60px;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.eaecho-audio-row audio {
    flex: 1;
    height: 36px;
    border-radius: 6px;
}

/* Record button */
.eaecho-record-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 4px;
}

.eaecho-record-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 18px;
    border-radius: 7px;
    border: 2px solid #e24b4a;
    background: transparent;
    color: #a32d2d;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background .15s;
}

.eaecho-record-btn:hover {
    background: #fff5f5;
}

.eaecho-record-btn.is-recording {
    background: #fff5f5;
    animation: eaecho-pulse .9s infinite;
}

.eaecho-rec-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #e24b4a;
    display: inline-block;
}

.eaecho-rec-dot.is-recording {
    animation: eaecho-pulse .7s infinite;
}

/* Playback row (appears after recording) */
.eaecho-playback-row {
    display: none;
    align-items: center;
    gap: 12px;
    margin-top: 8px;
}

.eaecho-playback-row.is-visible {
    display: flex;
}

.eaecho-playback-label {
    font-size: 12px;
    font-weight: 700;
    color: #27500a;
    min-width: 60px;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.eaecho-playback-row audio {
    flex: 1;
    height: 36px;
    border-radius: 6px;
}

/* Done badge */
.eaecho-done-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 10px;
    border-radius: 99px;
    background: #eaf3de;
    color: #27500a;
    font-size: 11px;
    font-weight: 600;
    margin-left: 10px;
}

/* Summary */
.eaecho-summary {
    display: none;
    background: #f0f7ff;
    border: 1px solid #b8d4f0;
    border-radius: 10px;
    padding: 16px 18px;
    margin-top: 16px;
    font-size: 15px;
    color: #0c447c;
    font-weight: 600;
}

.eaecho-summary.is-visible {
    display: block;
}

/* Hide text toggle */
.eaecho-footer {
    display: flex;
    justify-content: flex-end;
    margin-top: 10px;
}

.eaecho-hide-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 7px;
    border: 1px solid #533ab7;
    background: transparent;
    color: #533ab7;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background .15s;
}

.eaecho-hide-btn:hover {
    background: #f3f0ff;
}

@keyframes eaecho-pulse {
    0%, 100% { opacity: 1; }
    50%       { opacity: .4; }
}
