/* ── Magic House – Declarație Participare v1.2 ── */

#mh-decl-wrap {
    max-width: 800px;
    margin: 0 auto;
    font-family: 'Georgia', serif;
    color: #1a1a1a;
    padding: 0 16px 60px;
}

/* ── Switcher limbă ── */
.mh-lang-bar {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-bottom: 16px;
}

.mh-lang-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border: 2px solid #ddd;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    color: #555;
    transition: border-color .2s, color .2s, background .2s;
    font-family: inherit;
}

.mh-lang-btn:hover {
    border-color: #8b1a1a;
    color: #8b1a1a;
}

.mh-lang-btn.active {
    border-color: #8b1a1a;
    background: #8b1a1a;
    color: #fff;
}

.mh-flag {
    font-size: 20px;
    line-height: 1;
}

.mh-lang-label {
    font-size: 13px;
    letter-spacing: .05em;
}

/* ── Regulament ── */
.mh-decl-doc {
    background: #fff;
    border: 1px solid #d0d0d0;
    border-radius: 8px;
    padding: 36px 40px;
    margin-bottom: 36px;
    line-height: 1.75;
    font-size: 15px;
}

.mh-decl-doc h1 {
    text-align: center;
    font-size: 20px;
    letter-spacing: .05em;
    margin-bottom: 14px;
    text-transform: uppercase;
    border-bottom: 2px solid #1a1a1a;
    padding-bottom: 12px;
    color: #000;
}

.mh-decl-intro {
    margin-bottom: 10px;
    font-style: italic;
}

.mh-decl-body {
    margin-top: 6px;
    line-height: 1.8;
}

/* ── Formular ── */
.mh-decl-form-section {
    background: #fff;
    border: 1px solid #d0d0d0;
    border-radius: 8px;
    padding: 32px 40px;
}

.mh-field {
    margin-bottom: 20px;
}

.mh-field label {
    display: block;
    font-weight: bold;
    font-size: 13px;
    margin-bottom: 7px;
    letter-spacing: .03em;
    text-transform: uppercase;
    color: #333;
}

.mh-field .req { color: #c00; }

.mh-field input[type="text"],
.mh-field select {
    width: 100%;
    padding: 13px 15px;
    font-size: 17px;
    border: 2px solid #ccc;
    border-radius: 6px;
    outline: none;
    transition: border-color .2s;
    box-sizing: border-box;
    background: #fafafa;
    font-family: inherit;
}

.mh-field input[type="text"]:focus,
.mh-field select:focus {
    border-color: #8b1a1a;
    background: #fff;
}

/* ── Participanți multipli ── */
#mh-participants-wrap {
    margin-bottom: 8px;
}

.mh-participant-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.mh-participant-row .mh-field {
    flex: 1;
    margin-bottom: 0;
}

.mh-participant-row .mh-field label {
    display: flex;
    align-items: center;
    gap: 8px;
}

.mh-participant-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #8b1a1a;
    color: #fff;
    font-size: 11px;
    font-weight: bold;
    flex-shrink: 0;
}

.mh-btn-remove {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    margin-top: 26px;
    background: #fff;
    border: 2px solid #ddd;
    border-radius: 50%;
    font-size: 16px;
    color: #aaa;
    cursor: pointer;
    line-height: 1;
    transition: border-color .2s, color .2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mh-btn-remove:hover {
    border-color: #c00;
    color: #c00;
}

.mh-btn-add {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: #fff;
    border: 2px dashed #8b1a1a;
    border-radius: 8px;
    color: #8b1a1a;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    font-family: inherit;
    margin-bottom: 4px;
    transition: background .2s;
}

.mh-btn-add:hover {
    background: #fdf5f5;
}

/* ── Canvas semnătură ── */
.mh-sig-container {
    position: relative;
    border: 2px solid #ccc;
    border-radius: 6px;
    background: #fafafa;
    touch-action: none;
    overflow: hidden;
}

.mh-sig-container.active {
    border-color: #8b1a1a;
    background: #fff;
}

#mh-sig-canvas {
    display: block;
    width: 100%;
    height: 180px;
    cursor: crosshair;
}

.mh-btn-clear {
    position: absolute;
    top: 8px;
    right: 10px;
    background: rgba(255,255,255,.85);
    border: 1px solid #bbb;
    border-radius: 4px;
    padding: 4px 10px;
    font-size: 12px;
    cursor: pointer;
    color: #555;
}

.mh-btn-clear:hover { background:#fff; color:#c00; border-color:#c00; }

.mh-sig-hint {
    font-size: 12px;
    color: #888;
    margin-top: 6px;
    font-style: italic;
}

/* ── Eroare ── */
.mh-error {
    background: #fdecea;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 14px;
}

/* ── Buton submit ── */
.mh-btn-submit {
    display: block;
    width: 100%;
    padding: 18px;
    font-size: 17px;
    font-weight: bold;
    background: #8b1a1a;
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    letter-spacing: .05em;
    transition: background .2s, transform .1s;
    margin-top: 24px;
    font-family: inherit;
}

.mh-btn-submit:hover  { background: #6e1414; }
.mh-btn-submit:active { transform: scale(.98); }
.mh-btn-submit:disabled { background: #aaa; cursor: not-allowed; }

/* ── Overlay confirmare ── */
.mh-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.65);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: mhFadeIn .3s ease;
}

@keyframes mhFadeIn { from { opacity:0; } to { opacity:1; } }

.mh-overlay-box {
    background: #fff;
    border-radius: 16px;
    padding: 52px 48px;
    text-align: center;
    max-width: 420px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0,0,0,.35);
    animation: mhSlideUp .35s ease;
}

@keyframes mhSlideUp {
    from { transform:translateY(30px); opacity:0; }
    to   { transform:translateY(0);    opacity:1; }
}

.mh-overlay-icon {
    width: 84px;
    height: 84px;
    line-height: 84px;
    border-radius: 50%;
    background: #1e7e34;
    color: #fff;
    font-size: 40px;
    margin: 0 auto 22px;
}

.mh-overlay-box h2 { font-size:26px; color:#1e7e34; margin-bottom:12px; }
.mh-overlay-box p  { font-size:17px; color:#444; line-height:1.6; margin-bottom:10px; }

.mh-overlay-countdown { font-size:14px !important; color:#888 !important; margin-top:18px !important; }

#mh-countdown { font-weight:bold; color:#8b1a1a; font-size:16px; }

/* ── Tablet ── */
@media (max-width: 600px) {
    .mh-decl-doc,
    .mh-decl-form-section { padding: 24px 20px; }
    .mh-decl-doc { font-size:14px; }
    #mh-sig-canvas { height:160px; }
    .mh-overlay-box { padding:36px 24px; }
    .mh-lang-label { display:none; }
    .mh-lang-btn { padding:8px 10px; }
}
