/* ===============================
   Form container
   =============================== */
.ssf-form-container {
    max-width: 620px;
    margin: 20px auto;
    padding: 45px 50px;
    border-radius: 16px;
    background: #111 !important;
    box-shadow: 0 12px 40px rgba(0,0,0,0.6), 0 0 0 1px rgba(255,255,255,0.05);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: #fff;
    position: relative;
    display: block !important;
    visibility: visible !important;
}

/* ===============================
   Grid layout
   =============================== */
.ssf-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 20px;
}

.ssf-form .ssf-message-box,
.ssf-form button,
.ssf-form input[type="hidden"],
.ssf-form input[type="email"],
.ssf-form input[type="text"],
.ssf-full-width {
    grid-column: 1 / -1;
    width: 100%;
    box-sizing: border-box;
}

.ssf-divider {
    grid-column: 1 / -1;
    height: 1px;
    background: #2a2a2a;
    margin: 12px 0 28px;
}

/* ===============================
   Labels (div)
   =============================== */
.ssf-form-container .ssf-label {
    display: block;
    font-size: 11px;
    font-weight: 500;
    line-height: 1;
    color: #fff;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    margin: 0 0 6px 0;
    padding: 0;
}

/* ===============================
   Inputs
   =============================== */
.ssf-form-container input[type="email"],
.ssf-form-container input[type="text"] {
    width: 100%;
    padding: 11px 14px;
    font-size: 13px;
    margin-bottom: 18px;
    border: 1px solid #2a2a2a;
    border-radius: 10px;
    background: #1a1a1a;
    color: #fff;
    font-family: inherit;
    font-weight: 400;
    box-sizing: border-box;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.ssf-form-container input[type="email"]::placeholder,
.ssf-form-container input[type="text"]::placeholder {
    color: #555;
    font-size: 12px;
}

.ssf-form-container input[type="email"]:focus,
.ssf-form-container input[type="text"]:focus {
    border-color: #005cfb;
    background: #1e1e1e;
    box-shadow: 0 0 0 3px rgba(0,92,251,0.25);
}

.ssf-form-container input:-webkit-autofill {
    -webkit-box-shadow: 0 0 0px 1000px #1a1a1a inset;
    -webkit-text-fill-color: #fff;
}

/* ===============================
   Dropdown wrapper
   =============================== */
.sof-dd {
    position: relative;
    margin-bottom: 18px;
    user-select: none;
    -webkit-user-select: none;
}

/* ── Trigger ── */
.sof-dd__trigger {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    min-height: 42px;
    padding: 7px 14px;
    border: 1px solid #2a2a2a;
    border-radius: 10px;
    background: #1a1a1a;
    color: #fff;
    font-family: inherit;
    cursor: pointer;
    box-sizing: border-box;
    gap: 8px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

/* ── Tags inside trigger ── */
.sof-dd__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    flex: 1;
    align-items: center;
    min-height: 24px;
    padding: 2px 0;
}

.sof-dd__placeholder {
    color: #555;
    font-size: 12px;
    line-height: 24px;
}

.sof-dd__tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #005cfb;
    border-radius: 6px;
    padding: 3px 8px;
    font-size: 11px;
    font-weight: 500;
    color: #fff;
    max-width: 240px;
    line-height: 1.4;
}

.sof-dd__tag-label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sof-dd__tag-x {
    flex-shrink: 0;
    font-size: 15px;
    line-height: 1;
    opacity: 0.7;
    cursor: pointer;
    transition: opacity 0.15s;
}
.sof-dd__tag-x:hover { opacity: 1; }

.sof-dd__arrow {
    flex-shrink: 0;
    margin-top: 5px;
    transition: transform 0.2s ease;
    pointer-events: none;
}

/* ── Panel ── */
.sof-dd__panel {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 999999;
    background: #1a1a1a;
    border: 1px solid #005cfb;
    border-top: none;
    border-radius: 0 0 10px 10px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
    overflow: hidden;
}

/* ── Search inside panel ── */
.sof-dd__search-wrap {
    padding: 8px 10px;
    background: #1a1a1a;
    border-bottom: 1px solid #2a2a2a;
}

.sof-dd__search {
    width: 100% !important;
    padding: 7px 10px !important;
    margin-bottom: 0 !important;
    font-size: 12px !important;
    background: #111 !important;
    border: 1px solid #333 !important;
    border-radius: 6px !important;
    color: #fff !important;
    font-family: inherit !important;
    box-sizing: border-box !important;
    outline: none !important;
    box-shadow: none !important;
    transition: border-color 0.2s ease !important;
}

.sof-dd__search:focus {
    border-color: #005cfb !important;
    box-shadow: none !important;
}

.sof-dd__search::placeholder {
    color: #555 !important;
    font-size: 11px !important;
}

/* ── List ── */
.sof-dd__list {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
    max-height: 220px;
    overflow-y: auto;
}

.sof-dd__list::-webkit-scrollbar { width: 6px; }
.sof-dd__list::-webkit-scrollbar-track { background: #1a1a1a; }
.sof-dd__list::-webkit-scrollbar-thumb { background: #333; border-radius: 3px; }
.sof-dd__list::-webkit-scrollbar-thumb:hover { background: #005cfb; }

/* ── Options ── */
.sof-dd__option {
    display: flex !important;
    align-items: center;
    gap: 10px;
    padding: 9px 14px !important;
    font-size: 13px;
    color: #fff !important;
    cursor: pointer;
    border-bottom: 1px solid #222;
    list-style: none !important;
    transition: background 0.15s;
}

.sof-dd__option:last-child { border-bottom: none; }
.sof-dd__option:hover { background: rgba(0,92,251,0.15) !important; }
.sof-dd__option--checked { background: rgba(0,92,251,0.12) !important; }
.sof-dd__option--checked:hover { background: rgba(0,92,251,0.22) !important; }

.sof-dd__empty {
    padding: 12px 14px;
    color: #888;
    font-size: 13px;
    list-style: none !important;
}

/* ── Checkbox ── */
.sof-dd__cb {
    flex-shrink: 0;
    width: 14px;
    height: 14px;
    border: 1px solid #444;
    border-radius: 3px;
    background: #111;
    position: relative;
    transition: background 0.15s, border-color 0.15s;
}

.sof-dd__cb--checked {
    background: #005cfb !important;
    border-color: #005cfb !important;
}

.sof-dd__cb--checked::after {
    content: '';
    position: absolute;
    left: 3px;
    top: 0;
    width: 5px;
    height: 9px;
    border: 2px solid #fff;
    border-top: none;
    border-left: none;
    transform: rotate(42deg);
}

.sof-dd__label {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ===============================
   Button
   =============================== */
.ssf-form-container button[type="submit"] {
    width: 100%;
    padding: 12px 0;
    margin-top: 4px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, #005cfb, #0041c4) !important;
    color: #fff !important;
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.3px;
    transition: opacity 0.2s ease, transform 0.1s ease;
}

.ssf-form-container button[type="submit"]:hover { opacity: 0.88; }
.ssf-form-container button[type="submit"]:active { transform: scale(0.99); }

/* ===============================
   Messages
   =============================== */
.ssf-message-box {
    margin-bottom: 18px;
    padding: 11px 14px;
    font-size: 12px;
    border-radius: 8px;
    line-height: 1.5;
}

.ssf-error {
    background-color: rgba(255,59,48,0.15);
    color: #ff6b6b;
    border: 1px solid rgba(255,59,48,0.4);
    border-left: 4px solid #ff3b30;
    font-weight: 500;
}

.ssf-success {
    background-color: rgba(40,199,111,0.15);
    color: #4cd97b;
    border: 1px solid rgba(40,199,111,0.4);
    border-left: 4px solid #28c76f;
    font-weight: 500;
}

/* ===============================
   Responsive
   =============================== */
@media (max-width: 680px) {
    .ssf-form-container {
        padding: 30px 20px !important;
        margin: 20px auto !important;
        width: 92% !important;
        box-sizing: border-box !important;
    }
    .ssf-form { grid-template-columns: 1fr; }
}