/* ════════════════════════════════════════════════════════════════════
   TravelZona — Components CSS (reusable UI primitives)
   Loaded on every page via @import in style.css.
   Glass, cards, buttons, inputs, modals, badges.
   ════════════════════════════════════════════════════════════════════ */

/* ─── 4. Components ────────────────────────── */

/* Glass effect */
.glass {
    background: #ffffff;  /* solid white in light mode (was translucent 0.7) */
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm); /* add depth */
}
html.dark .glass {
    background: rgba(24, 24, 27, 0.7);
}

.glass-strong {
    background: #ffffff;  /* solid white in light mode */
    backdrop-filter: blur(16px);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-md); /* stronger shadow */
}
html.dark .glass-strong {
    background: rgba(24, 24, 27, 0.95);
}

/* Cards */
.card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 1rem;
    overflow: hidden;
}

.card-hover {
    transition: transform 0.2s, box-shadow 0.2s;
}
.card-hover:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Buttons */
.btn-primary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem;
    border: none;
    background: linear-gradient(135deg, var(--brand-500), #8b5cf6);
    color: white;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.75rem;
    cursor: pointer;
    box-shadow: var(--shadow-md);
    transition: box-shadow 0.2s, transform 0.1s;
}
.btn-primary:hover {
    box-shadow: 0 0 20px rgba(14, 165, 233, 0.4);
}
.btn-primary:active {
    transform: scale(0.98);
}

.btn-secondary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem 1.25rem;
    border: 1px solid var(--border);
    background: var(--card);
    color: var(--foreground);
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: background 0.2s;
}
.btn-secondary:hover {
    background: var(--muted);
}

/* Inputs */
.form-group {
    margin-bottom: 1rem;
}
.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.375rem;
}
.input-wrapper {
    position: relative;
}
.input-wrapper i {
    position: absolute;
    left: 0.875rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--muted-foreground);
    font-size: 0.875rem;
}
.input-wrapper input,
.input-wrapper textarea {
    width: 100%;
    padding: 0.625rem 1rem 0.625rem 2.5rem;
    background: var(--muted);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    color: var(--foreground);
    font-size: 0.875rem;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.input-wrapper input:focus,
.input-wrapper textarea:focus {
    border-color: var(--brand-500);
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
}

/* Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}
.modal-overlay.hidden {
    display: none;
}
.modal-content {
    background: var(--card);
    border-radius: 1rem;
    width: 100%;
    max-width: 28rem;
    padding: 1.5rem;
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
    position: relative;
}
.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 2rem;
    height: 2rem;
    border: none;
    background: var(--muted);
    border-radius: 0.5rem;
    font-size: 1.25rem;
    cursor: pointer;
    color: var(--foreground);
}

.auth-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}
.auth-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}
.auth-subtitle {
    font-size: 0.875rem;
    color: var(--muted-foreground);
    margin-bottom: 1.5rem;
}
.auth-form {
    margin-bottom: 1rem;
}
.auth-switch {
    text-align: center;
    font-size: 0.875rem;
    color: var(--muted-foreground);
}
.auth-switch a {
    color: var(--brand-500);
    font-weight: 600;
}

/* Badge pills */
.badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.625rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
}
