/* ============================================================
   Sarah's Tent Gallery – Commission Form Modal
   Matches site: white bg, dark text, red accent, clean minimal
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@400;500;600&family=Montserrat:wght@300;400;500;600&display=swap');

:root {
    --stc-white:       #FFFFFF;
    --stc-bg:          #F9F9F9;
    --stc-black:       #1A1A1A;
    --stc-dark:        #2C2C2C;
    --stc-mid:         #555555;
    --stc-soft:        #888888;
    --stc-border:      #DDDDDD;
    --stc-red:         #C0392B;
    --stc-error:       #C0392B;
    --stc-success-bg:  #F0F7F4;
    --stc-success-txt: #2D6A4F;
    --stc-font-display: 'Cormorant Garamond', Georgia, serif;
    --stc-font-body:    'Montserrat', sans-serif;
}

/* ── Overlay ── */
.stc-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 99999;
    overflow-y: auto;
    padding: 30px 16px 60px;
}
.stc-overlay.stc-active {
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

/* ── Modal Box ── */
.stc-modal {
    position: relative;
    background: var(--stc-white);
    width: 100%;
    max-width: 700px;
    box-shadow: 0 12px 50px rgba(0,0,0,0.22);
    font-family: var(--stc-font-body);
}

/* ── Close Button ── */
.stc-close {
    position: absolute;
    top: 16px;
    right: 20px;
    width: 32px;
    height: 32px;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.4);
    color: rgba(255,255,255,0.8);
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: background 0.2s, border-color 0.2s;
}
.stc-close:hover {
    background: rgba(255,255,255,0.15);
    border-color: rgba(255,255,255,0.7);
}

/* ── Header ── */
.stc-modal-header {
    background: var(--stc-black);
    padding: 36px 40px 30px;
}
.stc-header-label {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--stc-red);
    margin-bottom: 10px;
}
.stc-modal-header h2 {
    font-family: var(--stc-font-display);
    font-weight: 500;
    font-size: clamp(24px, 3.5vw, 30px);
    color: var(--stc-white);
    margin: 0 0 14px;
    line-height: 1.2;
}
.stc-header-desc {
    font-size: 12px;
    font-weight: 300;
    line-height: 1.8;
    color: rgba(255,255,255,0.6);
    margin: 0;
}

/* ── Form Body ── */
#stc-commission-form {
    padding: 0 40px 40px;
}

/* ── Section ── */
.stc-section {
    padding-top: 28px;
    margin-top: 28px;
    border-top: 1px solid var(--stc-border);
}
.stc-section:first-of-type {
    border-top: none;
    margin-top: 0;
    padding-top: 32px;
}

.stc-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}
.stc-section-title-text {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--stc-black);
}
.stc-section-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    background: var(--stc-black);
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    flex-shrink: 0;
}

.stc-subsection-label {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--stc-soft);
    margin: 8px 0 14px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--stc-border);
}

/* ── Fields ── */
.stc-field { margin-bottom: 15px; }
.stc-field:last-child { margin-bottom: 0; }

.stc-field label {
    display: block;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--stc-dark);
    margin-bottom: 7px;
}
.stc-req { color: var(--stc-red); }

.stc-field input[type="text"],
.stc-field input[type="email"],
.stc-field input[type="tel"],
.stc-field input[type="number"],
.stc-field input[type="date"],
.stc-field select,
.stc-field textarea {
    width: 100%;
    box-sizing: border-box;
    background: var(--stc-white);
    border: 1px solid var(--stc-border);
    border-radius: 0;
    padding: 11px 14px;
    font-family: var(--stc-font-body);
    font-size: 13px;
    font-weight: 300;
    color: var(--stc-dark);
    transition: border-color 0.2s;
    appearance: none;
    -webkit-appearance: none;
    outline: none;
}
.stc-field input::placeholder,
.stc-field textarea::placeholder { color: #BBBBBB; font-weight: 300; }

.stc-field select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' fill='none'%3E%3Cpath stroke='%23555' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m1 1 4 4 4-4'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
    cursor: pointer;
}
.stc-field input:focus,
.stc-field select:focus,
.stc-field textarea:focus { border-color: var(--stc-black); }
.stc-field input.stc-invalid,
.stc-field select.stc-invalid,
.stc-field textarea.stc-invalid { border-color: var(--stc-red); }
.stc-field textarea { resize: vertical; min-height: 80px; }

/* ── Two-column ── */
.stc-row.stc-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}
@media (max-width: 520px) {
    .stc-row.stc-two-col { grid-template-columns: 1fr; }
    #stc-commission-form { padding: 0 20px 32px; }
    .stc-modal-header { padding: 28px 20px 24px; }
    .stc-gallery-section { margin-left: -20px; margin-right: -20px; padding: 24px 20px; }
}

/* ── Size Row ── */
.stc-size-row { display: flex; align-items: center; gap: 10px; }
.stc-size-input { position: relative; flex: 1; }
.stc-size-input input { padding-right: 26px; }
.stc-size-label {
    position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
    font-size: 9px; font-weight: 700; letter-spacing: 0.08em; color: var(--stc-soft); pointer-events: none;
}
.stc-size-x { font-size: 15px; color: var(--stc-soft); flex-shrink: 0; }
.stc-size-row select { width: auto; flex-shrink: 0; padding: 11px 32px 11px 12px; }

/* ── Radio Group ── */
.stc-radio-group { display: flex; gap: 24px; flex-wrap: wrap; }
.stc-radio-label {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 13px; font-weight: 300; color: var(--stc-dark);
    cursor: pointer; text-transform: none; letter-spacing: 0;
}
.stc-radio-label input[type="radio"] {
    width: 15px; height: 15px; accent-color: var(--stc-black); flex-shrink: 0;
}

/* ── Timeline note ── */
.stc-timeline-note {
    font-size: 12px; font-weight: 300; color: var(--stc-mid);
    background: var(--stc-bg); border-left: 3px solid var(--stc-black);
    padding: 10px 14px; margin-bottom: 18px; line-height: 1.6;
}

/* ── Dropzone ── */
.stc-dropzone {
    border: 1px dashed #C0C0C0; padding: 28px 20px; text-align: center;
    cursor: pointer; transition: border-color 0.2s, background 0.2s; background: var(--stc-bg);
}
.stc-dropzone:hover, .stc-dropzone.stc-drag-over {
    border-color: var(--stc-black); background: #F2F2F2;
}
.stc-dropzone-icon { color: #C0C0C0; margin-bottom: 8px; }
.stc-dropzone-text { font-size: 13px; font-weight: 300; color: var(--stc-dark); margin: 0 0 5px; }
.stc-browse-link { color: var(--stc-red); text-decoration: underline; cursor: pointer; font-weight: 500; }
.stc-dropzone-hint { font-size: 11px; color: var(--stc-soft); margin: 0; }

/* ── File List ── */
.stc-file-list { margin-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.stc-file-item {
    display: flex; align-items: center; gap: 10px;
    background: var(--stc-bg); border: 1px solid var(--stc-border);
    padding: 9px 12px; font-size: 12px; color: var(--stc-dark);
}
.stc-file-item svg { flex-shrink: 0; color: var(--stc-soft); }
.stc-file-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stc-file-size { font-size: 11px; color: var(--stc-soft); flex-shrink: 0; }
.stc-file-remove {
    flex-shrink: 0; background: none; border: none; cursor: pointer;
    color: #C0C0C0; padding: 0; font-size: 18px; line-height: 1; transition: color 0.15s;
}
.stc-file-remove:hover { color: var(--stc-red); }

/* ── Gallery Section ── */
.stc-gallery-section {
    background: var(--stc-bg);
    margin-left: -40px; margin-right: -40px;
    padding: 30px 40px; border-top: 1px solid var(--stc-border);
    margin-top: 28px; text-align: center;
}
.stc-gallery-section .stc-section-title { justify-content: center; }
.stc-gallery-desc {
    font-size: 13px; font-weight: 300; line-height: 1.8;
    color: var(--stc-mid); margin: 0 auto 22px; max-width: 520px;
}
.stc-gallery-btn {
    display: inline-flex; align-items: center; gap: 8px;
    background: var(--stc-black); color: #fff !important;
    text-decoration: none !important; font-size: 11px; font-weight: 600;
    letter-spacing: 0.12em; text-transform: uppercase;
    padding: 13px 30px; transition: background 0.2s;
}
.stc-gallery-btn:hover { background: #333; }

/* ── Next Steps ── */
.stc-next-steps {
    display: flex; align-items: flex-start; gap: 10px;
    background: var(--stc-bg); border: 1px solid var(--stc-border);
    border-left: 3px solid var(--stc-black); padding: 13px 16px;
    font-size: 12px; font-weight: 300; color: var(--stc-mid);
    line-height: 1.6; margin-top: 28px;
}
.stc-next-steps svg { flex-shrink: 0; margin-top: 1px; color: var(--stc-black); }

/* ── Submit Button – matches "Contact Sarah's Tent Gallery" black button ── */
.stc-submit-btn {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    width: 100%; margin-top: 24px; padding: 15px;
    background: var(--stc-black); color: #fff; border: none;
    font-family: var(--stc-font-body); font-size: 11px; font-weight: 600;
    letter-spacing: 0.14em; text-transform: uppercase;
    cursor: pointer; transition: background 0.2s;
}
.stc-submit-btn:hover:not(:disabled) { background: #333; }
.stc-submit-btn:disabled { opacity: 0.6; cursor: not-allowed; }

@keyframes stcSpin { to { transform: rotate(360deg); } }
.stc-spin { animation: stcSpin 0.8s linear infinite; }

/* ── Response Message ── */
.stc-response-msg {
    margin-top: 14px; padding: 12px 16px;
    font-size: 12px; font-weight: 300; line-height: 1.6; display: none;
}
.stc-response-msg.stc-msg-success {
    background: var(--stc-success-bg); border: 1px solid #B7DDD0;
    color: var(--stc-success-txt); display: block;
}
.stc-response-msg.stc-msg-error {
    background: #FDF0EF; border: 1px solid #F1C0BB;
    color: var(--stc-error); display: block;
}
