/* ========================================
   DICED REGISTRATION - Popup + Form + Success
   ======================================== */

/* ===== POPUP OVERLAY ===== */
.diced-reg-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(13, 40, 24, 0.85);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(4px);
    animation: dicedRegFadeIn 0.3s ease;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

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

.diced-reg-popup {
    background: #ffffff;
    border-radius: 24px;
    max-width: 520px;
    width: 100%;
    position: relative;
    overflow: hidden;
    box-shadow: 0 30px 80px rgba(0,0,0,0.4);
    animation: dicedRegSlideUp 0.4s ease;
    max-height: 90vh;
    max-height: 90dvh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    margin: auto;
}

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

.diced-reg-popup-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(255,255,255,0.2);
    border: none;
    color: #ffffff;
    font-size: 24px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    z-index: 2;
    transition: all 0.2s;
}
.diced-reg-popup-close:hover {
    background: rgba(255,255,255,0.3);
    transform: scale(1.1);
}

/* Popup Logo Area */
.diced-reg-popup-logo {
    background: linear-gradient(145deg, #0d2818 0%, #1B4332 40%, #2D6A4F 100%);
    padding: 32px 24px 28px;
    text-align: center;
}
.diced-reg-logo-img {
    max-width: 200px;
    height: auto;
}

/* Popup Body */
.diced-reg-popup-body {
    padding: 24px 28px 20px;
    font-family: 'Outfit', -apple-system, sans-serif;
}

.diced-reg-popup-title {
    font-size: 24px;
    font-weight: 900;
    color: #1B4332;
    margin: 0 0 16px 0;
    text-align: center;
    line-height: 1.2;
}
.diced-reg-popup-title span {
    color: #52B788;
}

/* GDPR Notice */
.diced-reg-popup-notice {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #FFF8E1;
    border: 2px solid #FFECB3;
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 12px;
}
.diced-reg-popup-notice-icon {
    font-size: 20px;
    flex-shrink: 0;
}
.diced-reg-popup-notice p {
    font-size: 13px;
    color: #92400E;
    line-height: 1.5;
    margin: 0;
}

/* Gift Box */
.diced-reg-popup-gift {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #D8F3DC;
    border: 2px solid #A7F3D0;
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 24px;
}
.diced-reg-popup-gift-icon {
    font-size: 24px;
    flex-shrink: 0;
}
.diced-reg-popup-gift p {
    font-size: 14px;
    color: #1B4332;
    line-height: 1.5;
    margin: 0;
}
.diced-reg-popup-gift strong {
    color: #1B4332;
}

/* Popup Buttons */
.diced-reg-popup-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 12px;
}

.diced-reg-popup-btn-primary {
    display: block;
    width: 100%;
    padding: 16px 20px;
    background: #D4A017;
    color: #0d2818;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    font-family: 'Outfit', sans-serif;
    transition: all 0.2s;
    box-sizing: border-box;
}
.diced-reg-popup-btn-primary:hover {
    background: #e8b520;
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(212,160,23,0.35);
    color: #0d2818;
    text-decoration: none;
}

.diced-reg-popup-btn-secondary {
    display: block;
    width: 100%;
    padding: 14px 20px;
    background: transparent;
    color: #1B4332;
    border: 2px solid #1B4332;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    font-family: 'Outfit', sans-serif;
    transition: all 0.2s;
    box-sizing: border-box;
}
.diced-reg-popup-btn-secondary:hover {
    background: #1B4332;
    color: #ffffff;
    text-decoration: none;
}

.diced-reg-popup-skip {
    display: block;
    width: 100%;
    background: none;
    border: none;
    color: #9CA3AF;
    font-size: 13px;
    cursor: pointer;
    padding: 8px;
    font-family: 'Outfit', sans-serif;
    transition: color 0.2s;
    text-align: center;
}
.diced-reg-popup-skip:hover {
    color: #6B7280;
}


/* ===== REGISTRATION FORM ===== */

.diced-register-wrap {
    max-width: 680px;
    margin: 0 auto;
    font-family: 'Outfit', -apple-system, sans-serif;
}

/* Gift Banner */
.diced-reg-gift-banner {
    display: flex;
    align-items: center;
    gap: 14px;
    background: linear-gradient(135deg, #1B4332 0%, #2D6A4F 100%);
    color: #ffffff;
    padding: 18px 24px;
    border-radius: 14px;
    margin-bottom: 28px;
}
.diced-reg-gift-emoji {
    font-size: 32px;
    flex-shrink: 0;
}
.diced-reg-gift-banner strong {
    font-size: 17px;
    display: block;
    margin-bottom: 2px;
}
.diced-reg-gift-banner span {
    font-size: 13px;
    opacity: 0.85;
}

/* Form */
.diced-reg-form {
    background: #ffffff;
    border: 2px solid #E5E7EB;
    border-radius: 16px;
    padding: 32px 28px;
}

.diced-reg-section-title {
    font-size: 16px;
    font-weight: 800;
    color: #1B4332;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin: 28px 0 16px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid #D8F3DC;
}
.diced-reg-section-title:first-child {
    margin-top: 0;
}

.diced-reg-row {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
}

.diced-reg-field {
    flex: 1;
}
.diced-reg-full {
    margin-bottom: 16px;
}

.diced-reg-field label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: #1B4332;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.diced-reg-field input {
    width: 100%;
    padding: 13px 16px;
    border: 2px solid #E5E7EB;
    border-radius: 10px;
    font-size: 15px;
    font-family: 'Outfit', sans-serif;
    color: #374151;
    background: #ffffff;
    box-sizing: border-box;
    transition: border-color 0.2s;
}
.diced-reg-field input:focus {
    border-color: #1B4332;
    outline: none;
    box-shadow: 0 0 0 3px rgba(27,67,50,0.1);
}
.diced-reg-field input.diced-reg-input-error {
    border-color: #C62828;
    box-shadow: 0 0 0 3px rgba(198,40,40,0.1);
}

/* Password Strength */
.diced-reg-strength {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    padding: 0 2px;
}
.diced-reg-strength-bar {
    flex: 1;
    height: 6px;
    background: #E5E7EB;
    border-radius: 3px;
    overflow: hidden;
}
.diced-reg-strength-fill {
    height: 100%;
    width: 0%;
    border-radius: 3px;
    transition: all 0.3s ease;
}
.diced-reg-strength-text {
    font-size: 12px;
    font-weight: 700;
    min-width: 60px;
    text-align: right;
}

/* Marketing Consent */
.diced-reg-consent {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 20px;
}

.diced-reg-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    padding: 14px 16px;
    background: #F8F9FA;
    border: 2px solid #E5E7EB;
    border-radius: 10px;
    transition: all 0.2s;
}
.diced-reg-checkbox:hover {
    border-color: #2D6A4F;
    background: #F0FFF4;
}

.diced-reg-checkbox input[type="checkbox"] {
    display: none;
}

.diced-reg-checkmark {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border: 2px solid #D1D5DB;
    border-radius: 6px;
    flex-shrink: 0;
    transition: all 0.2s;
    margin-top: 1px;
}
.diced-reg-checkmark::after {
    content: '';
    display: none;
    width: 6px;
    height: 10px;
    border: solid #ffffff;
    border-width: 0 2.5px 2.5px 0;
    transform: rotate(45deg);
    margin-top: -2px;
}

.diced-reg-checkbox input:checked ~ .diced-reg-checkmark {
    background: #1B4332;
    border-color: #1B4332;
}
.diced-reg-checkbox input:checked ~ .diced-reg-checkmark::after {
    display: block;
}
.diced-reg-checkbox input:checked ~ span:last-child {
    color: #1B4332;
}

.diced-reg-checkbox span:last-child {
    font-size: 14px;
    color: #374151;
    line-height: 1.5;
}

/* Privacy */
.diced-reg-privacy {
    font-size: 12px;
    color: #9CA3AF;
    line-height: 1.6;
    margin-bottom: 24px;
    text-align: center;
}
.diced-reg-privacy a {
    color: #1B4332;
    font-weight: 600;
}

/* Submit */
.diced-reg-submit-row {
    margin-bottom: 16px;
}

.diced-reg-btn-submit {
    display: block;
    width: 100%;
    padding: 18px 24px;
    background: #D4A017;
    color: #0d2818;
    border: none;
    border-radius: 10px;
    font-size: 17px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    font-family: 'Outfit', sans-serif;
    transition: all 0.2s;
}
.diced-reg-btn-submit:hover {
    background: #e8b520;
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(212,160,23,0.35);
}
.diced-reg-btn-submit:disabled {
    background: #9CA3AF;
    cursor: wait;
    transform: none;
    box-shadow: none;
}

/* Error */
.diced-reg-error {
    background: #FEE2E2;
    border: 2px solid #FECACA;
    border-radius: 10px;
    padding: 14px 18px;
    font-size: 14px;
    color: #991B1B;
    margin-bottom: 16px;
    text-align: center;
    line-height: 1.5;
}
.diced-reg-error a {
    color: #1B4332;
    font-weight: 700;
}

/* Login Link */
.diced-reg-login-link {
    text-align: center;
    font-size: 14px;
    color: #6B7280;
}
.diced-reg-login-link a {
    color: #1B4332;
    font-weight: 700;
}


/* ===== SUCCESS STATE ===== */

.diced-reg-success {
    text-align: center;
    padding: 20px 0;
    animation: dicedRegSlideUp 0.5s ease;
}

.diced-reg-success-confetti {
    font-size: 64px;
    margin-bottom: 16px;
}

.diced-reg-success-title {
    font-size: 32px;
    font-weight: 900;
    color: #1B4332;
    margin: 0 0 8px 0;
}

.diced-reg-success-text {
    font-size: 16px;
    color: #6B7280;
    margin: 0 0 28px 0;
}

/* Coupon Box */
.diced-reg-coupon-box {
    background: linear-gradient(135deg, #1B4332 0%, #2D6A4F 100%);
    border-radius: 16px;
    padding: 28px 24px;
    margin-bottom: 28px;
}

.diced-reg-coupon-label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: rgba(255,255,255,0.7);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 12px;
}

.diced-reg-coupon-code {
    font-size: 36px;
    font-weight: 900;
    color: #D4A017;
    letter-spacing: 4px;
    margin-bottom: 14px;
    font-family: 'Outfit', monospace;
    word-break: break-all;
}

.diced-reg-coupon-copy {
    display: inline-block;
    padding: 10px 28px;
    background: #D4A017;
    color: #0d2818;
    border: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    cursor: pointer;
    font-family: 'Outfit', sans-serif;
    transition: all 0.2s;
    margin-bottom: 14px;
}
.diced-reg-coupon-copy:hover {
    background: #e8b520;
}

.diced-reg-coupon-note {
    font-size: 12px;
    color: rgba(255,255,255,0.6);
    margin: 0;
    line-height: 1.5;
}

/* Success Actions */
.diced-reg-success-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.diced-reg-btn-primary {
    display: block;
    padding: 16px 24px;
    background: #D4A017;
    color: #0d2818;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    text-align: center;
    text-decoration: none;
    transition: all 0.2s;
}
.diced-reg-btn-primary:hover {
    background: #e8b520;
    color: #0d2818;
    text-decoration: none;
}

.diced-reg-btn-secondary {
    display: block;
    padding: 14px 24px;
    background: transparent;
    color: #1B4332;
    border: 2px solid #1B4332;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
    transition: all 0.2s;
}
.diced-reg-btn-secondary:hover {
    background: #1B4332;
    color: #ffffff;
    text-decoration: none;
}

/* Already Registered */
.diced-reg-already {
    text-align: center;
    padding: 40px 20px;
}
.diced-reg-already-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    background: #D8F3DC;
    color: #1B4332;
    border-radius: 50%;
    font-size: 32px;
    font-weight: 900;
    margin-bottom: 16px;
}
.diced-reg-already h3 {
    font-size: 24px;
    font-weight: 800;
    color: #1B4332;
    margin: 0 0 8px 0;
}
.diced-reg-already p {
    font-size: 16px;
    color: #6B7280;
    margin: 0 0 24px 0;
}


/* ===== MOBILE ===== */
@media (max-width: 600px) {
    .diced-reg-overlay {
        align-items: flex-start;
        padding: 10px;
    }
    .diced-reg-popup {
        border-radius: 18px;
        max-height: 95vh;
        max-height: 95dvh;
        margin: auto;
    }
    .diced-reg-popup-body {
        padding: 20px 16px 18px;
    }
    .diced-reg-popup-title {
        font-size: 20px;
    }
    .diced-reg-popup-notice {
        padding: 12px 14px;
    }
    .diced-reg-popup-notice p {
        font-size: 12px;
    }
    .diced-reg-popup-gift {
        padding: 12px 14px;
        margin-bottom: 18px;
    }
    .diced-reg-popup-gift p {
        font-size: 13px;
    }
    .diced-reg-popup-btn-primary {
        padding: 14px 18px;
        font-size: 14px;
    }
    .diced-reg-popup-btn-secondary {
        padding: 12px 18px;
        font-size: 13px;
    }
    .diced-reg-popup-logo {
        padding: 20px 16px 16px;
    }
    .diced-reg-logo-img {
        max-width: 160px;
    }
    .diced-reg-row {
        flex-direction: column;
        gap: 12px;
    }
    .diced-reg-form {
        padding: 24px 18px;
    }
    .diced-reg-coupon-code {
        font-size: 26px;
        letter-spacing: 2px;
    }
}
