/* Modern Forms + Toast + Modal — THOR Photomedicine */

/* ── CTA buttons ── */
.blue-button, .cta-btn {
    display: inline-block;
    padding: 12px 28px !important;
    background: #0061b4 !important;
    color: #fff !important;
    border-radius: 6px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    text-decoration: none !important;
    transition: background 0.2s ease, transform 0.15s ease !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    border: none !important;
    letter-spacing: 0;
}
.blue-button:hover, .cta-btn:hover {
    background: #004a8f !important;
    transform: translateY(-1px);
    text-decoration: none !important;
    color: #fff !important;
}

/* ── Toast ── */
.thor-toast-container {
    position: fixed; top: 20px; right: 20px;
    z-index: 99999; display: flex; flex-direction: column; gap: 10px;
}
.thor-toast {
    padding: 14px 20px; border-radius: 8px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 14px; color: #fff;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    animation: thorToastIn 0.3s ease; max-width: 360px; line-height: 1.4;
}
.thor-toast.success { background: #0d9f6e; }
.thor-toast.error   { background: #dc2626; }
.thor-toast.info    { background: #0061b4; }
.thor-toast.fadeout { animation: thorToastOut 0.3s ease forwards; }
@keyframes thorToastIn  { from { opacity:0; transform:translateX(30px); } to { opacity:1; transform:translateX(0); } }
@keyframes thorToastOut { to   { opacity:0; transform:translateX(30px); } }

/* ── Modal ── */
.thor-modal-overlay {
    display: none; position: fixed; inset: 0;
    background: rgba(0,0,0,0.45); z-index: 99998;
    align-items: center; justify-content: center;
}
.thor-modal-overlay.active { display: flex; }
.thor-modal {
    background: #fff; border-radius: 12px; padding: 36px 32px;
    max-width: 440px; width: 90%; text-align: center;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    animation: thorModalIn 0.25s ease;
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}
.thor-modal h3 { margin: 0 0 10px; font-size: 20px; color: #111; font-weight: 700; }
.thor-modal p  { margin: 0 0 20px; color: #555; font-size: 15px; line-height: 1.5; }
.thor-modal .modal-icon { font-size: 44px; margin-bottom: 12px; }
.thor-modal .modal-btn {
    display: inline-block; padding: 11px 30px;
    background: #0061b4; color: #fff; border: none;
    border-radius: 6px; font-size: 14px; font-weight: 600;
    cursor: pointer; text-decoration: none;
    transition: background 0.2s ease;
}
.thor-modal .modal-btn:hover { background: #004a8f; }
@keyframes thorModalIn { from { opacity:0; transform:scale(0.96); } to { opacity:1; transform:scale(1); } }

/* ── Enquiry form card wrapper ── */
#sidebar_enquiry_form_wrapper,
#enquiry_section {
    background: #fff !important;
    border: 1px solid #dde3ec !important;
    border-radius: 12px !important;
    padding: 24px !important;
    box-shadow: 0 2px 16px rgba(0,0,0,0.07) !important;
}
.ns-heading {
    font-size: 17px !important;
    font-weight: 700 !important;
    color: #1a1a2e !important;
    margin: 0 0 4px !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    letter-spacing: -0.02em !important;
}
.form-note {
    font-size: 12px !important;
    color: #6b7280 !important;
    margin: 0 0 20px !important;
    line-height: 1.4 !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

/* ── Core form reset — beat thor-2.css global !important rules ── */
/* thor-2.css sets: border:1px solid #7F9DB9 !important; padding:3px; font:11px ...
   We need ID-level specificity + !important to win */
#sidebar_enquiry_form {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}
#sidebar_enquiry_form .form-group {
    margin-bottom: 14px !important;
    clear: none !important;
    overflow: visible !important;
    padding: 0 !important;
}
#sidebar_enquiry_form label {
    display: block !important;
    float: none !important;
    width: auto !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    color: #374151 !important;
    margin: 0 0 5px !important;
    padding: 0 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.04em !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}
#sidebar_enquiry_form label .req { color: #0061b4 !important; }

#sidebar_enquiry_form input[type="text"],
#sidebar_enquiry_form input[type="email"],
#sidebar_enquiry_form input[type="tel"],
#sidebar_enquiry_form select,
#sidebar_enquiry_form textarea {
    display: block !important;
    width: 100% !important;
    padding: 10px 12px !important;
    font-size: 14px !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    line-height: 1.5 !important;
    color: #1d1d1f !important;
    background: #f9fafb !important;
    border: 1.5px solid #d1d5db !important;
    border-radius: 7px !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    float: none !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    box-shadow: none !important;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease !important;
}
#sidebar_enquiry_form select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='11' height='7' viewBox='0 0 11 7'%3E%3Cpath d='M1 1l4.5 4.5L10 1' stroke='%230061b4' stroke-width='1.6' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 12px center !important;
    padding-right: 32px !important;
}
#sidebar_enquiry_form input[type="text"]:focus,
#sidebar_enquiry_form input[type="email"]:focus,
#sidebar_enquiry_form input[type="tel"]:focus,
#sidebar_enquiry_form select:focus,
#sidebar_enquiry_form textarea:focus {
    outline: none !important;
    border-color: #0061b4 !important;
    background: #fff !important;
    box-shadow: 0 0 0 3px rgba(0,97,180,0.12) !important;
}
#sidebar_enquiry_form input.invalid,
#sidebar_enquiry_form select.invalid,
#sidebar_enquiry_form textarea.invalid {
    border-color: #dc2626 !important;
    box-shadow: 0 0 0 3px rgba(220,38,38,0.1) !important;
}
#sidebar_enquiry_form textarea {
    resize: vertical !important;
    min-height: 85px !important;
    max-height: 180px !important;
}
#sidebar_enquiry_form .submit-btn {
    display: block !important;
    width: 100% !important;
    padding: 12px 16px !important;
    background: #0061b4 !important;
    color: #fff !important;
    border: none !important;
    border-radius: 7px !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    margin-top: 6px !important;
    transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease !important;
    box-shadow: none !important;
    letter-spacing: 0 !important;
}
#sidebar_enquiry_form .submit-btn:hover {
    background: #004a8f !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 14px rgba(0,97,180,0.25) !important;
}
#sidebar_enquiry_form .submit-btn:active  { transform: translateY(0) !important; box-shadow: none !important; }
#sidebar_enquiry_form .submit-btn:disabled { background: #9ca3af !important; cursor: not-allowed !important; transform: none !important; }

/* ── styledform (purchase-enquiry page) ── */
.styledform .form-group { margin-bottom: 14px; }
.styledform label {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 12px; font-weight: 600; color: #374151;
    margin-bottom: 5px; text-transform: uppercase; letter-spacing: 0.04em;
}
.styledform .input,
.styledform select,
.styledform textarea {
    width: 100% !important; max-width: 100% !important;
    padding: 10px 12px !important; font-size: 14px !important;
    border: 1.5px solid #d1d5db !important; border-radius: 7px !important;
    background: #f9fafb !important; color: #1d1d1f !important;
    box-sizing: border-box !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    transition: border-color 0.18s, box-shadow 0.18s !important;
}
.styledform .input:focus,
.styledform select:focus,
.styledform textarea:focus {
    outline: none !important; border-color: #0061b4 !important;
    box-shadow: 0 0 0 3px rgba(0,97,180,0.12) !important; background: #fff !important;
}
.styledform .submit {
    width: 100%; padding: 12px 24px !important;
    background: #0061b4 !important; color: #fff !important;
    border: none !important; border-radius: 7px !important;
    font-size: 15px !important; font-weight: 600 !important;
    cursor: pointer !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    transition: background 0.2s !important;
}
.styledform .submit:hover    { background: #004a8f !important; }
.styledform .submit:disabled { background: #9ca3af !important; cursor: not-allowed !important; }

/* ── Form messages ── */
.form-message.success {
    background: #f0fdf4 !important; color: #166534 !important;
    border: 1px solid #bbf7d0 !important; border-radius: 7px !important;
    font-size: 14px !important; padding: 12px 14px !important;
}
.form-message.error {
    background: #fef2f2 !important; color: #991b1b !important;
    border: 1px solid #fecaca !important; border-radius: 7px !important;
    font-size: 14px !important; padding: 12px 14px !important;
}
