/* 
 * Afsona Trip - Main Stylesheet
 * Compiled CSS for Hostinger deployment (no build step required)
 */

/* ==========================================
   CSS Variables (Uzbekistan-inspired palette)
   ========================================== */
:root {
    /* Warm sand/cream base */
    --background: 35 30% 96%;
    --foreground: 25 25% 15%;

    /* Cards with warm cream */
    --card: 35 40% 98%;
    --card-foreground: 25 25% 15%;

    /* Popovers */
    --popover: 35 40% 99%;
    --popover-foreground: 25 25% 15%;

    /* Primary - Rich Teal (like Uzbek tiles) */
    --primary: 175 45% 35%;
    --primary-foreground: 35 40% 98%;

    /* Secondary - Warm Sand */
    --secondary: 35 25% 90%;
    --secondary-foreground: 25 25% 20%;

    /* Muted tones */
    --muted: 35 20% 92%;
    --muted-foreground: 25 15% 45%;

    /* Accent - Gold (like Uzbek ornaments) */
    --accent: 40 70% 50%;
    --accent-foreground: 25 25% 10%;

    /* Destructive */
    --destructive: 0 65% 50%;
    --destructive-foreground: 35 40% 98%;

    /* Borders */
    --border: 35 20% 85%;
    --input: 35 25% 88%;
    --ring: 175 45% 35%;

    --radius: 0.75rem;

    /* Custom colors */
    --teal: 175 45% 35%;
    --teal-light: 175 40% 45%;
    --teal-dark: 175 50% 25%;
    --gold: 40 70% 50%;
    --gold-light: 40 65% 60%;
    --sand: 35 30% 96%;
    --sand-dark: 35 25% 85%;
    --terracotta: 15 50% 55%;
}

/* ==========================================
   Base Styles
   ========================================== */
*, *::before, *::after {
    box-sizing: border-box;
    border-color: hsl(var(--border));
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background-color: hsl(var(--background));
    color: hsl(var(--foreground));
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1.5;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', Georgia, serif;
    margin: 0;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

/* ==========================================
   Utility Classes
   ========================================== */
.container {
    width: 100%;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 2rem;
    padding-right: 2rem;
}

.font-display {
    font-family: 'Playfair Display', Georgia, serif;
}

.font-sans {
    font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
}

/* Colors */
.bg-background { background-color: hsl(var(--background)); }
.bg-foreground { background-color: hsl(var(--foreground)); }
.bg-card { background-color: hsl(var(--card)); }
.bg-primary { background-color: hsl(var(--primary)); }
.bg-primary\/10 { background-color: hsl(var(--primary) / 0.1); }
.bg-gold { background-color: hsl(var(--gold)); }
.bg-pattern {
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23408a80' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.text-foreground { color: hsl(var(--foreground)); }
.text-background { color: hsl(var(--background)); }
.text-card { color: hsl(var(--card)); }
.text-primary { color: hsl(var(--primary)); }
.text-primary-foreground { color: hsl(var(--primary-foreground)); }
.text-muted-foreground { color: hsl(var(--muted-foreground)); }
.text-accent-foreground { color: hsl(var(--accent-foreground)); }

/* Spacing */
.min-h-screen { min-height: 100vh; }
.min-h-\[calc\(100vh-80px\)\] { min-height: calc(100vh - 80px); }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }
.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.py-0\.5 { padding-top: 0.125rem; padding-bottom: 0.125rem; }
.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.p-4 { padding: 1rem; }
.p-5 { padding: 1.25rem; }
.p-6 { padding: 1.5rem; }
.pt-3 { padding-top: 0.75rem; }
.pt-24 { padding-top: 6rem; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-12 { margin-bottom: 3rem; }
.mt-1\.5 { margin-top: 0.375rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-8 { margin-top: 2rem; }
.mr-2 { margin-right: 0.5rem; }
.ml-2 { margin-left: 0.5rem; }
.mx-2 { margin-left: 0.5rem; margin-right: 0.5rem; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* Flexbox */
.flex { display: flex; }
.inline-flex { display: inline-flex; }
.flex-col { flex-direction: column; }
.flex-1 { flex: 1 1 0%; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.gap-1 { gap: 0.25rem; }
.gap-1\.5 { gap: 0.375rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }
.space-y-2 > * + * { margin-top: 0.5rem; }
.space-y-3 > * + * { margin-top: 0.75rem; }
.space-y-6 > * + * { margin-top: 1.5rem; }

/* Grid */
.grid { display: grid; }
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }

/* Typography */
.text-xs { font-size: 0.75rem; line-height: 1rem; }
.text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; }
.text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.text-center { text-align: center; }
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Sizing */
.w-full { width: 100%; }
.w-6 { width: 1.5rem; }
.w-8 { width: 2rem; }
.w-10 { width: 2.5rem; }
.w-24 { width: 6rem; }
.w-4 { width: 1rem; }
.w-5 { width: 1.25rem; }
.w-3\.5 { width: 0.875rem; }
.h-0\.5 { height: 0.125rem; }
.h-3\.5 { height: 0.875rem; }
.h-4 { height: 1rem; }
.h-5 { height: 1.25rem; }
.h-6 { height: 1.5rem; }
.h-8 { height: 2rem; }
.h-10 { height: 2.5rem; }
.h-12 { height: 3rem; }
.h-16 { height: 4rem; }
.h-24 { height: 6rem; }
.h-40 { height: 10rem; }
.h-48 { height: 12rem; }

/* SVG icon sizing fix */
svg.h-4 { width: 1rem; height: 1rem; flex-shrink: 0; }
svg.h-5 { width: 1.25rem; height: 1.25rem; flex-shrink: 0; }
svg.h-3\.5 { width: 0.875rem; height: 0.875rem; flex-shrink: 0; }
.max-w-2xl { max-width: 42rem; }
.max-w-4xl { max-width: 56rem; }
.max-w-sm { max-width: 24rem; }
.max-w-md { max-width: 28rem; }

/* Borders */
.border { border-width: 1px; }
.border-t { border-top-width: 1px; }
.border-b { border-bottom-width: 1px; }
.border-border { border-color: hsl(var(--border)); }
.border-border\/50 { border-color: hsl(var(--border) / 0.5); }
.border-primary\/20 { border-color: hsl(var(--primary) / 0.2); }
.border-background\/20 { border-color: hsl(var(--background) / 0.2); }
.rounded-lg { border-radius: var(--radius); }
.rounded-xl { border-radius: calc(var(--radius) + 0.25rem); }
.rounded-full { border-radius: 9999px; }

/* Effects */
.shadow-md { box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1); }
.shadow-lg { box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1); }
.shadow-xl { box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1); }
.backdrop-blur-md { backdrop-filter: blur(12px); }

/* Positioning */
.relative { position: relative; }
.absolute { position: absolute; }
.fixed { position: fixed; }
.inset-0 { top: 0; right: 0; bottom: 0; left: 0; }
.top-0 { top: 0; }
.top-3 { top: 0.75rem; }
.right-0 { right: 0; }
.right-3 { right: 0.75rem; }
.right-4 { right: 1rem; }
.bottom-4 { bottom: 1rem; }
.left-0 { left: 0; }
.left-3 { left: 0.75rem; }
.left-4 { left: 1rem; }
.z-50 { z-index: 50; }

/* Overflow */
.overflow-hidden { overflow: hidden; }

/* Visibility */
.hidden { display: none; }
.invisible { visibility: hidden; }

/* Transitions */
.transition-all { transition-property: all; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-colors { transition-property: color, background-color, border-color; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-transform { transition-property: transform; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.duration-300 { transition-duration: 300ms; }
.duration-500 { transition-duration: 500ms; }

/* Cursor */
.cursor-pointer { cursor: pointer; }

/* Object fit */
.object-cover { object-fit: cover; }

/* Gradients */
.bg-gradient-to-t { background-image: linear-gradient(to top, var(--tw-gradient-stops)); }
.bg-gradient-to-br { background-image: linear-gradient(to bottom right, var(--tw-gradient-stops)); }
.from-foreground\/60 { --tw-gradient-from: hsl(var(--foreground) / 0.6); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-foreground\/70 { --tw-gradient-from: hsl(var(--foreground) / 0.7); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-primary\/10 { --tw-gradient-from: hsl(var(--primary) / 0.1); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.via-primary\/5 { --tw-gradient-stops: var(--tw-gradient-from), hsl(var(--primary) / 0.05), var(--tw-gradient-to, transparent); }
.to-transparent { --tw-gradient-to: transparent; }
.to-gold\/10 { --tw-gradient-to: hsl(var(--gold) / 0.1); }

/* ==========================================
   Component Styles
   ========================================== */

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: var(--radius);
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    outline: none;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-hero {
    background: linear-gradient(135deg, hsl(var(--primary)) 0%, hsl(var(--teal-dark)) 100%);
    color: hsl(var(--primary-foreground));
    box-shadow: 0 4px 14px 0 hsl(var(--primary) / 0.3);
}

.btn-hero:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px 0 hsl(var(--primary) / 0.4);
}

.btn-ghost {
    background: transparent;
    color: hsl(var(--foreground));
}

.btn-ghost:hover:not(:disabled) {
    background: hsl(var(--muted));
}

.btn-outline-teal {
    background: transparent;
    color: hsl(var(--primary));
    border: 1px solid hsl(var(--primary));
}

.btn-outline-teal:hover:not(:disabled) {
    background: hsl(var(--primary) / 0.1);
}

.btn-xl {
    padding: 1rem 2rem;
    font-size: 1rem;
}

/* Input Fields */
.input-field {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    background-color: hsl(var(--card));
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    color: hsl(var(--foreground));
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input-field:focus {
    outline: none;
    border-color: hsl(var(--primary));
    box-shadow: 0 0 0 3px hsl(var(--primary) / 0.1);
}

.input-field::placeholder {
    color: hsl(var(--muted-foreground));
}

/* Trip Cards */
.trip-card {
    border: 2px solid transparent;
}

.trip-card.selected {
    border-color: hsl(var(--primary));
    box-shadow: 0 0 0 2px hsl(var(--primary) / 0.2);
}

.trip-card.selected .selected-indicator {
    display: flex;
}

.trip-card:hover {
    transform: translateY(-4px);
}

/* Date Cards */
.date-card {
    padding: 1.5rem;
    background: hsl(var(--card));
    border: 2px solid hsl(var(--border));
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.2s ease;
}

.date-card:hover {
    border-color: hsl(var(--primary) / 0.5);
    background: hsl(var(--primary) / 0.05);
}

.date-card.selected {
    border-color: hsl(var(--primary));
    background: hsl(var(--primary) / 0.1);
}

.date-card.selected .date-check {
    display: flex;
}

.date-card.sold-out {
    opacity: 0.6;
    cursor: not-allowed;
    background: hsl(var(--muted));
}

.date-card.sold-out:hover {
    border-color: hsl(var(--border));
    background: hsl(var(--muted));
}

/* Availability spots badge */
.spots-badge {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    border-radius: 9999px;
    background-color: hsl(var(--primary) / 0.1);
    color: hsl(var(--primary));
}

.spots-badge.low {
    background-color: hsl(40 100% 50% / 0.15);
    color: hsl(30 80% 40%);
}

.spots-badge.sold-out {
    background-color: hsl(var(--destructive) / 0.1);
    color: hsl(var(--destructive));
}

/* Date Chips (available dates preview) */
.date-chip,
span.text-xs.bg-primary\/10 {
    display: inline-block;
    font-size: 0.75rem;
    background-color: hsl(var(--primary) / 0.1);
    color: hsl(var(--primary));
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    white-space: nowrap;
}

/* Price Badge */
.price-badge {
    display: inline-block;
    background-color: hsl(var(--gold));
    color: hsl(var(--accent-foreground));
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 600;
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1);
}

/* Step Indicator */
.step-indicator-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
}

.step-circle {
    width: 2.5rem;
    height: 2.5rem;
    min-width: 2.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: hsl(var(--muted));
    color: hsl(var(--muted-foreground));
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
}

.step-circle.active {
    background: hsl(var(--primary));
    color: hsl(var(--primary-foreground));
}

.step-circle.completed {
    background: hsl(var(--primary));
    color: hsl(var(--primary-foreground));
}

.step-circle.completed .step-number {
    display: none;
}

.step-circle.completed .step-check {
    display: block;
}

.step-line {
    flex: 1;
    height: 2px;
    background: hsl(var(--border));
    transition: background 0.3s ease;
    margin: 0 0.5rem;
    align-self: center;
}

.step-line.completed {
    background: hsl(var(--primary));
}

/* Step item wrapper for label alignment */
.step-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
}

.step-label {
    font-size: 0.65rem;
    color: hsl(var(--muted-foreground));
    text-align: center;
    flex: 1;
    padding: 0 0.25rem;
}

@media (min-width: 640px) {
    .step-label {
        font-size: 0.75rem;
    }
}

/* Header */
header {
    background-color: hsl(var(--background) / 0.8);
}

/* Toast */
.toast {
    padding: 1rem 1.5rem;
    background: hsl(var(--card));
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    animation: slideIn 0.3s ease;
}

.toast-success {
    border-left: 4px solid hsl(var(--primary));
}

.toast-error {
    border-left: 4px solid hsl(var(--destructive));
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* ==========================================
   Responsive Styles
   ========================================== */
@media (min-width: 768px) {
    .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .md\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .md\:flex { display: flex; }
    .md\:hidden { display: none; }
    .md\:py-16 { padding-top: 4rem; padding-bottom: 4rem; }
    .md\:text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
}

@media (min-width: 1024px) {
    .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Group hover effects */
.group:hover .group-hover\:scale-110 {
    transform: scale(1.1);
}

/* Hover translate */
.hover\:-translate-y-1:hover {
    transform: translateY(-0.25rem);
}
