/* ============================================================
   Add-decorated-house modal, opened by the footer "+" button.
   Mobile-first "bottom sheet": slides up flush with the bottom
   edge on phones; becomes a floating rounded card on wider
   screens.
   ============================================================ */

.add-house-overlay {
    position: fixed;
    inset: 0;
    z-index: var(--z-modal);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    background: rgba(0, 0, 0, 0.7);
}

.add-house-sheet {
    position: relative;
    width: 100%;
    max-width: 420px;
    max-height: 80vh;
    overflow-y: auto;
    background: #1a1a1a;
    border: none;
    border-radius: var(--radius-md) var(--radius-md) 0 0;
    box-shadow: var(--shadow-strong);
    padding: var(--space-2) var(--space-4) var(--space-4);
    transform: translateY(100%);
    transition: transform var(--transition-base);
}

.add-house-overlay.show .add-house-sheet {
    transform: translateY(0);
}

.add-house-handle {
    width: 36px;
    height: 4px;
    background: #555;
    border-radius: 2px;
    margin: var(--space-2) auto var(--space-3);
}

.add-house-close {
    position: absolute;
    top: var(--space-2);
    right: var(--space-3);
    background: none;
    border: none;
    color: #6e6c6c;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    transition: color 0.15s;
}

.add-house-close:hover {
    color: #fff;
}

.add-house-title {
    font-family: var(--font-body);
    font-size: 15px;
    font-weight: 600;
    color: #fff;
    margin: 0 0 var(--space-2);
    text-align: center;
}

.add-house-intro {
    font-size: 12.5px;
    line-height: 1.4;
    color: #6e6c6c;
    text-align: center;
    margin: 0 0 var(--space-3);
}

.add-house-qr {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3);
    margin-bottom: var(--space-3);
    background: #111;
    border: 1px solid #2a2a2a;
    border-radius: var(--radius-sm);
    text-align: center;
}

.add-house-qr img {
    width: 140px;
    height: 140px;
    border-radius: var(--radius-sm);
}

.add-house-qr p {
    margin: 0;
    font-size: 12px;
    line-height: 1.4;
    color: #6e6c6c;
}

.add-house-qr-actions {
    text-align: center;
}

.add-house-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

.add-house-form label {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
    font-size: 12.5px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #6e6c6c;
}

.add-house-form input,
.add-house-form select {
    font-family: var(--font-body);
    font-size: var(--text-base);
    font-weight: 400;
    text-transform: none;
    letter-spacing: normal;
    min-height: var(--touch-min);
    padding: var(--space-2) var(--space-3);
    border-radius: var(--radius-sm);
    border: 1px solid #2a2a2a;
    background: #252525;
    color: #fff;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.add-house-form input:hover,
.add-house-form select:hover {
    border-color: #ee8a04;
}

.add-house-form input:focus,
.add-house-form select:focus {
    outline: none;
    border-color: #ee8a04;
    box-shadow: 0 0 0 3px rgba(238, 138, 4, 0.25);
}

.add-house-form input::placeholder {
    color: #6e6c6c;
    opacity: 1;
}

.add-house-form select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236e6c6c' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right var(--space-3) center;
    padding-right: var(--space-7);
    cursor: pointer;
}

.add-house-time-row {
    display: flex;
    gap: var(--space-3);
}

.add-house-time-row label {
    flex: 1;
    min-width: 0;
}

.add-house-hint {
    font-size: 11px;
    font-weight: 400;
    text-transform: none;
    letter-spacing: normal;
    color: #6e6c6c;
}

/* ---- "Aparecer em Primeiro Lugar" — premium teaser row (see
   premium-modal.js) — reskinned with this site's own tokens instead of the
   raw hex the rest of this file still uses (ported from Airsoft, never
   retokenized). ---- */
.add-house-featured-heading {
    display: block;
    font-size: 12.5px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #6e6c6c;
    margin-top: var(--space-1);
}

.add-house-featured-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-3);
    padding: var(--space-2) var(--space-3);
    background: rgba(244, 208, 63, 0.06);
    border: 1px solid rgba(244, 208, 63, 0.25);
    border-radius: var(--radius-sm);
}

.add-house-featured-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.add-house-featured-name {
    font-size: 12.5px;
    font-weight: 600;
    text-transform: none;
    letter-spacing: normal;
    color: var(--color-text);
}

.add-house-featured-hint {
    font-size: 11px;
    font-weight: 400;
    color: var(--color-text-muted);
}

/* Scoped to .add-house-featured-row (not just .add-house-toggle-wrap alone)
   so this out-specificities the generic ".add-house-form label" rule above
   — .add-house-toggle-wrap IS a <label>, and that rule would otherwise win
   (it's more specific: class+element vs. this class alone) and force
   display:flex;flex-direction:column onto it, breaking the switch's
   side-by-side layout. */
.add-house-featured-row .add-house-toggle-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
    cursor: pointer;
}

.add-house-toggle-input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.add-house-toggle-slider {
    display: block;
    width: 34px;
    height: 18px;
    background: #2a2a2a;
    border-radius: var(--radius-pill);
    transition: background var(--transition-fast);
    position: relative;
}

.add-house-toggle-slider::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #666;
    transition: transform var(--transition-fast), background var(--transition-fast);
}

.add-house-toggle-input:checked + .add-house-toggle-slider {
    background: rgba(244, 208, 63, 0.25);
}

.add-house-toggle-input:checked + .add-house-toggle-slider::after {
    transform: translateX(16px);
    background: var(--color-gold-bright);
}

.add-house-form input[type="file"] {
    min-height: unset;
    padding: var(--space-2);
    color: #6e6c6c;
    font-size: 12.5px;
    cursor: pointer;
}

.add-house-form input[type="file"]::file-selector-button {
    font-family: var(--font-body);
    font-size: 12.5px;
    font-weight: 600;
    padding: var(--space-1) var(--space-3);
    margin-right: var(--space-2);
    border: none;
    border-radius: var(--radius-sm);
    background: #ee8a04;
    color: #fff;
    cursor: pointer;
}

.add-house-photo-preview {
    display: flex;
    gap: var(--space-2);
    margin-top: calc(-1 * var(--space-1));
}

.add-house-photo-square {
    position: relative;
    width: 64px;
    height: 64px;
    border-radius: var(--radius-sm);
    border: 1px solid #2a2a2a;
    background: #252525;
    overflow: hidden;
}

.add-house-photo-square img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.add-house-photo-remove {
    position: absolute;
    top: 3px;
    right: 3px;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.65);
    color: #fff;
    font-size: 15px;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.15s;
}

.add-house-photo-remove:hover {
    background: #ee8a04;
}

.add-house-location-status {
    font-size: 12.5px;
    color: #6e6c6c;
    margin: 0;
    text-align: center;
}

.add-house-progress {
    display: none;
    height: 6px;
    border-radius: var(--radius-pill);
    background: #2a2a2a;
    overflow: hidden;
}

.add-house-progress.show {
    display: block;
}

.add-house-progress-bar {
    width: 0%;
    height: 100%;
    background: #ee8a04;
    border-radius: var(--radius-pill);
    transition: width 0.15s ease;
}

.add-house-submit {
    font-family: var(--font-body);
    font-size: var(--text-base);
    font-weight: 600;
    padding: var(--space-2) var(--space-4);
    border-radius: var(--radius-pill);
    border: none;
    background: #ee8a04;
    color: #fff;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.add-house-submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Desktop / tablet: floating rounded card instead of an
   edge-to-edge sheet, still sliding up from the bottom. */
@media (min-width: 768px) {
    .add-house-sheet {
        max-width: 380px;
        border-radius: var(--radius-md);
        margin-bottom: var(--space-5);
    }
}
