/* ============================================
   MAISON DISENAJE - Client Form Page Styles
   Page-specific styles that extend the main site
   ============================================ */

/* ============ SCREEN MANAGEMENT ============ */
.screen {
    min-height: 100vh;
    min-height: 100dvh;
    width: 100%;
    display: none;
    position: relative;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.screen.active {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transform: translateY(0);
    animation: fadeInUp 0.8s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ================================================
   SCREEN 1: WELCOME PAGE
   ================================================ */
#screen-1 {
    background: var(--brown-deep);
    overflow: hidden;
}

#screen-1 .hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://cdn.prod.website-files.com/696741f4daff1fc6ce093366/69674814b9b338410213177c_background.png') center/cover no-repeat;
    z-index: -2;
}

#screen-1 .hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.1) 30%, rgba(0,0,0,0.4) 70%, rgba(26,15,8,0.9) 100%);
    z-index: -1;
}

#screen-1 .hero-content {
    text-align: center;
    padding: 0 30px;
    max-width: 800px;
    z-index: 1;
    margin-top: 80px;
}

/* Title Decorations */
.title-decoration {
    width: 200px;
    height: 1px;
    margin: 0 auto;
    position: relative;
    background: linear-gradient(90deg, transparent 0%, var(--gold-primary) 50%, transparent 100%);
    opacity: 0.6;
}

.title-decoration.top {
    margin-bottom: 18px;
}

.title-decoration.top::before {
    content: '';
    position: absolute;
    top: -3px;
    left: 50%;
    transform: translateX(-50%) rotate(45deg);
    width: 7px;
    height: 7px;
    border: 1px solid var(--gold-primary);
    background: var(--brown-deep);
}

.title-decoration.bottom {
    margin-top: 18px;
    margin-bottom: 20px;
}

/* Title Styling for Screen 1 */
#screen-1 h1 {
    font-family: var(--font-primary);
    font-weight: 300;
    letter-spacing: 2px;
    margin-bottom: 0;
    color: var(--cream);
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    line-height: 1.3;
}

.title-prefix {
    display: block;
    font-size: clamp(1.2rem, 3vw, 1.6rem);
    font-style: italic;
    font-weight: 300;
    color: var(--gold-light);
    letter-spacing: 3px;
    margin-bottom: 5px;
}

.title-main {
    display: block;
    font-family: var(--font-primary);
    font-size: clamp(2rem, 6vw, 3.5rem);
    font-weight: 400;
    letter-spacing: 6px;
    text-transform: uppercase;
    color: var(--cream);
}

/* Hero Subtitle */
#screen-1 .hero-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    font-style: italic;
    font-weight: 300;
    color: var(--gold-light);
    margin-bottom: 25px;
    letter-spacing: 1px;
    opacity: 0.9;
    text-transform: none;
}

/* Welcome Description */
#screen-1 .welcome-description {
    margin: 0 auto 30px;
    max-width: 600px;
}

#screen-1 .welcome-description p {
    font-size: clamp(0.9rem, 2vw, 1rem);
    margin-bottom: 14px;
    color: rgba(245, 230, 200, 0.8);
    line-height: 1.6;
    font-weight: 300;
}

/* Hero Footer - Contact Icons */
.hero-footer {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 30px;
    z-index: 10;
}

.footer-icon {
    width: 44px;
    height: 44px;
    border: 1px solid var(--gold-border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gold-light);
    transition: all 0.3s ease;
    background: rgba(0, 0, 0, 0.3);
    text-decoration: none;
}

.footer-icon:hover {
    border-color: var(--gold-primary);
    background: rgba(201, 169, 98, 0.15);
    transform: translateY(-3px);
    color: var(--gold-primary);
}

.footer-icon svg {
    width: 20px;
    height: 20px;
}

/* ================================================
   SCREEN 2: COLLECTIONS & FORM
   ================================================ */
#screen-2 {
    background: var(--brown-deep);
    justify-content: flex-start;
    padding-top: 120px;
    overflow-y: auto;
}

#screen-2 .hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://cdn.prod.website-files.com/696741f4daff1fc6ce093366/69674814b9b338410213177c_background.png') center/cover no-repeat;
    z-index: -2;
}

#screen-2 .hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(26,15,8,0.9) 0%, rgba(26,15,8,0.85) 100%);
    z-index: -1;
}

.content-wrapper {
    width: 100%;
    max-width: 1400px;
    padding: 0 20px 60px;
    text-align: center;
}

.content-wrapper h2 {
    font-family: var(--font-primary);
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 400;
    letter-spacing: 3px;
    margin-bottom: 15px;
    color: var(--cream);
}

.subtitle {
    font-size: clamp(0.9rem, 1.5vw, 1.1rem);
    color: var(--gold-light);
    margin-bottom: 15px;
    font-weight: 300;
    font-style: italic;
}

.collections-intro {
    max-width: 800px;
    margin: 0 auto 20px;
    text-align: center;
}

.collections-intro p {
    font-size: clamp(0.9rem, 1.6vw, 1rem);
    color: rgba(245, 230, 200, 0.7);
    margin-bottom: 8px;
    line-height: 1.6;
}

/* ============ CAROUSEL ============ */
.carousel-container {
    position: relative;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto 40px;
    padding: 20px 60px;
    overflow: hidden;
}

.carousel {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    padding: 20px 5px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.carousel::-webkit-scrollbar {
    display: none;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(135deg, var(--gold-primary) 0%, var(--gold-dark) 100%);
    border: none;
    color: var(--brown-deep);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.8rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    box-shadow: 0 4px 20px rgba(201, 169, 98, 0.4);
}

.carousel-btn:hover {
    background: var(--gold-primary);
    transform: translateY(-50%) scale(1.15);
    box-shadow: 0 6px 30px rgba(201, 169, 98, 0.6);
}

.carousel-btn:active {
    transform: translateY(-50%) scale(0.95);
}

.carousel-btn.prev {
    left: 5px;
}

.carousel-btn.next {
    right: 5px;
}

/* Carousel Indicators */
.carousel-indicators {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.carousel-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(201, 169, 98, 0.3);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.carousel-dot.active {
    background: var(--gold-primary);
    transform: scale(1.2);
    box-shadow: 0 0 10px rgba(201, 169, 98, 0.5);
}

.carousel-dot:hover {
    background: rgba(201, 169, 98, 0.6);
}

.carousel-note {
    font-size: 0.85rem;
    color: rgba(245, 230, 200, 0.5);
    font-style: italic;
    margin-top: 15px;
    margin-bottom: 40px;
}

/* ============ FLIP CARDS ============ */
.flip-card {
    flex: 0 0 calc((100% - 40px) / 3);
    min-width: 280px;
    height: 450px;
    perspective: 1000px;
    scroll-snap-align: center;
    transition: transform 0.4s ease, opacity 0.4s ease;
}

.flip-card:hover {
    transform: translateY(-5px);
}

.flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
}

.flip-card:hover .flip-card-inner {
    transform: rotateY(180deg);
}

.flip-card-front,
.flip-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
}

.flip-card-front {
    background: var(--brown-dark);
}

.flip-card-back {
    background: linear-gradient(135deg, rgba(42, 24, 16, 0.98) 0%, rgba(26, 15, 8, 0.98) 100%);
    transform: rotateY(180deg);
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    text-align: center;
    border: 1px solid var(--gold-border);
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
}

.card-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    position: relative;
}

/* Card Images */
.historia-sabor {
    background: url('https://cdn.prod.website-files.com/696741f4daff1fc6ce093366/69674802e6d1e1cb275e4ebf_Entre%20Historia%20y%20Sabor.png') center/cover;
}

.cafe-pablo {
    background: url('https://cdn.prod.website-files.com/696741f4daff1fc6ce093366/696748023f48d4a7f45ab71a_Anado%20el%20Cafe%2C%20Odiando%20a%20Pablo.png') center/cover;
}

.masquerada {
    background: url('https://cdn.prod.website-files.com/696741f4daff1fc6ce093366/69674803eae077b876e9f802_La%20Masquerada.png') center/cover;
}

.noche-blanca {
    background: url('https://cdn.prod.website-files.com/696741f4daff1fc6ce093366/696748032d8d29db306dea44_La%20Noche%20Blanca.png') center/cover;
}

.concorso {
    background: url('https://cdn.prod.website-files.com/696741f4daff1fc6ce093366/6967480282f5796ae6cfa54c_Il%20Concorso.png') center/cover;
}

.historia-familiar {
    background: url('https://cdn.prod.website-files.com/696741f4daff1fc6ce093366/6967480342a4c142634fa785_Entre%20Historia%20y%20Sabor%20-%20Edicion%20familiar.png') center/cover;
}

.card-label {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 25px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0.7) 70%, transparent 100%);
}

.card-label h3 {
    font-family: var(--font-primary);
    font-size: 1.2rem;
    letter-spacing: 1px;
    margin-bottom: 0;
    color: var(--gold-primary);
    line-height: 1.3;
}

/* Card Back Content */
.flip-card-back h3 {
    font-family: var(--font-primary);
    font-size: 1.4rem;
    color: var(--gold-primary);
    letter-spacing: 2px;
    margin-bottom: 10px;
    line-height: 1.3;
}

.flip-card-back .temporada {
    font-size: 0.95rem;
    color: var(--gold-light);
    margin-bottom: 12px;
    font-style: italic;
    line-height: 1.5;
}

.flip-card-back .temporada .nota-familia {
    font-size: 0.85rem;
    text-transform: lowercase;
    opacity: 0.8;
}

.flip-card-back .concepto {
    font-size: 0.95rem;
    line-height: 1.6;
    color: rgba(245, 230, 200, 0.9);
    margin-bottom: 12px;
    flex-grow: 1;
    align-content: center;
}

.flip-card-back .estado {
    font-size: 0.9rem;
    color: var(--gold-primary);
    padding: 8px 12px;
    background: rgba(201, 169, 98, 0.15);
    border: 1px solid var(--gold-border);
    border-radius: 4px;
    margin-bottom: 15px;
    line-height: 1.5;
}

/* Button adjustments for flip card back */
.flip-card-back .btn-primary {
    max-width: 100%;
    margin: 0;
}

.flip-card-back .btn-inner {
    font-size: 14px;
    padding: 12px 20px;
}

/* Selected state for collection buttons */
.flip-card-back .btn-primary.selected .btn-inner {
    background: rgba(74, 124, 78, 0.9);
    border-color: rgba(74, 124, 78, 0.8);
    box-shadow:
        0 0 20px rgba(74, 124, 78, 0.5),
        inset 0 0 20px rgba(74, 124, 78, 0.2);
    color: #fff;
}

/* ============ FORM SECTION ============ */
.form-section {
    max-width: 500px;
    margin: 60px auto 0;
    padding: 40px;
    background: rgba(42, 24, 16, 0.8);
    border-radius: 8px;
    border: 1px solid var(--gold-border);
    backdrop-filter: blur(10px);
}

.form-section h3 {
    font-family: var(--font-primary);
    font-size: 1.6rem;
    margin-bottom: 10px;
    letter-spacing: 1px;
    color: var(--cream);
}

.form-section > p {
    font-size: 0.95rem;
    color: var(--gold-light);
    margin-bottom: 30px;
    font-style: italic;
}

#contact-form input,
#contact-form select {
    width: 100%;
    padding: 16px;
    margin-bottom: 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--gold-border);
    border-radius: 4px;
    color: var(--cream);
    font-family: var(--font-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
}

#contact-form input:focus,
#contact-form select:focus {
    outline: none;
    border-color: var(--gold-primary);
    background: rgba(255, 255, 255, 0.08);
}

#contact-form input::placeholder {
    color: rgba(245, 230, 200, 0.4);
}

#contact-form select option {
    background: var(--brown-dark);
    color: var(--cream);
}

#contact-form .btn-primary {
    width: 100%;
    max-width: 100%;
    margin: 0;
}

/* ================================================
   SCREEN 3: THANK YOU PAGE
   ================================================ */
#screen-3 {
    background: var(--brown-deep);
    justify-content: flex-start;
    padding-top: 120px;
    overflow-y: auto;
}

#screen-3 .hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://cdn.prod.website-files.com/696741f4daff1fc6ce093366/69674814b9b338410213177c_background.png') center/cover no-repeat;
    z-index: -2;
}

#screen-3 .hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(26,15,8,0.9) 0%, rgba(26,15,8,0.85) 100%);
    z-index: -1;
}

.thank-you-content {
    width: 100%;
    max-width: 900px;
    padding: 0 20px 60px;
    text-align: center;
}

.decorative-line {
    width: 80px;
    height: 1px;
    background: var(--gold-primary);
    margin: 0 auto 40px;
    position: relative;
}

.decorative-line::before,
.decorative-line::after {
    content: '';
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--gold-primary);
    border-radius: 50%;
    top: -1.5px;
}

.decorative-line::before {
    left: -10px;
}

.decorative-line::after {
    right: -10px;
}

.thank-you-text {
    margin: 0 auto 40px;
    max-width: 700px;
}

.thank-you-text p {
    font-size: clamp(1rem, 1.5vw, 1.15rem);
    color: rgba(245, 230, 200, 0.85);
    margin-bottom: 20px;
    line-height: 1.8;
}

.next-steps {
    background: rgba(201, 169, 98, 0.08);
    border: 1px solid var(--gold-border);
    border-radius: 8px;
    padding: 40px;
    margin: 15px auto 30px;
    max-width: 600px;
}

.next-steps h3 {
    font-family: var(--font-primary);
    font-size: 1.4rem;
    color: var(--gold-primary);
    margin-bottom: 25px;
    letter-spacing: 1px;
}

.next-steps ul {
    list-style: none;
    padding: 0;
    text-align: left;
}

.next-steps li {
    font-size: 1.05rem;
    color: rgba(245, 230, 200, 0.9);
    padding: 15px 0;
    border-bottom: 1px solid rgba(201, 169, 98, 0.2);
    position: relative;
    padding-left: 30px;
}

.next-steps li:last-child {
    border-bottom: none;
}

.next-steps li::before {
    content: '\2713';
    position: absolute;
    left: 0;
    color: var(--gold-primary);
    font-weight: bold;
}

.thank-you-content .btn-primary {
    max-width: 450px;
    margin: 20px auto;
}

/* ================================================
   RESPONSIVE DESIGN
   ================================================ */

/* Mobile: Show 1 full card at a time */
@media (max-width: 767px) {
    #screen-1 .hero-content,
    #screen-2,
    #screen-3 {
        padding-top: 100px;
    }

    .carousel-container {
        padding: 15px 50px;
        margin-bottom: 20px;
    }

    .carousel {
        gap: 15px;
        padding: 15px 0;
    }

    .flip-card {
        flex: 0 0 100%;
        min-width: calc(100% - 10px);
        max-width: 350px;
        height: 480px;
        margin: 0 auto;
    }

    .carousel-btn {
        width: 40px;
        height: 40px;
        font-size: 1.4rem;
    }

    .carousel-btn.prev {
        left: 2px;
    }

    .carousel-btn.next {
        right: 2px;
    }

    /* Mobile: Disable hover flip, use tap instead */
    .flip-card:hover .flip-card-inner {
        transform: rotateY(0deg);
    }

    .flip-card.flipped .flip-card-inner {
        transform: rotateY(180deg);
    }

    .flip-card-back {
        padding: 20px 15px;
    }

    .flip-card-back h3 {
        font-size: 1.1rem;
    }

    .flip-card-back .concepto {
        font-size: 1rem;
    }

    .flip-card-back .btn-inner {
        font-size: 12px;
        padding: 10px 16px;
    }

    .form-section {
        padding: 25px 18px;
        margin: 40px auto 0;
    }

    .hero-footer {
        bottom: 25px;
        gap: 20px;
    }

    .footer-icon {
        width: 38px;
        height: 38px;
    }
}

/* Small Mobile (max 380px) */
@media (max-width: 380px) {
    .title-main {
        letter-spacing: 3px;
    }

    .flip-card {
        height: 450px;
    }

    .flip-card-back {
        padding: 15px 12px;
    }

    .flip-card-back h3 {
        font-size: 1rem;
    }

    .flip-card-back .btn-inner {
        font-size: 11px;
        padding: 8px 14px;
    }
}

/* Tablet: Show 2 cards */
@media (min-width: 768px) and (max-width: 1023px) {
    #screen-1 .hero-content {
        margin-top: 100px;
    }

    .carousel-container {
        padding: 20px 60px;
        max-width: 900px;
    }

    .flip-card {
        flex: 0 0 calc((100% - 20px) / 2);
        min-width: 300px;
        height: 460px;
    }

    .title-main {
        letter-spacing: 8px;
    }
}

/* Desktop: Show 3 cards */
@media (min-width: 1024px) {
    #screen-1 .hero-content {
        margin-top: 60px;
    }

    .carousel-container {
        max-width: 1200px;
        padding: 20px 70px;
    }

    .carousel {
        gap: 25px;
    }

    .flip-card {
        flex: 0 0 calc((100% - 50px) / 3);
        min-width: 320px;
        height: 480px;
    }

    .carousel-indicators {
        display: none;
    }

    .title-decoration {
        width: 300px;
    }

    .title-prefix {
        font-size: 1.5rem;
    }

    .title-main {
        font-size: 3.2rem;
        letter-spacing: 8px;
    }
}

/* Large Desktop (1440px+) */
@media (min-width: 1440px) {
    .carousel-container {
        max-width: 1400px;
        padding: 25px 80px;
    }

    .flip-card {
        flex: 0 0 calc((100% - 60px) / 3);
        min-width: 380px;
        height: 520px;
    }

    .title-main {
        font-size: 3.5rem;
        letter-spacing: 10px;
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    .flip-card:hover .flip-card-inner {
        transform: rotateY(0deg);
    }

    .flip-card.flipped .flip-card-inner {
        transform: rotateY(180deg);
    }
}

/* Landscape orientation for mobile */
@media (max-width: 896px) and (orientation: landscape) {
    #screen-1 .hero-content {
        margin-top: 80px;
    }

    .hero-footer {
        bottom: 15px;
    }

    .flip-card {
        min-width: 260px;
        height: 360px;
    }

    .flip-card-back {
        padding: 12px 10px;
    }

    .flip-card-back h3 {
        font-size: 0.95rem;
    }

    .flip-card-back .concepto {
        font-size: 0.75rem;
        line-height: 1.3;
    }

    .flip-card-back .btn-inner {
        font-size: 10px;
        padding: 6px 12px;
    }
}

/* Custom scrollbar for flip card back */
.flip-card-back::-webkit-scrollbar {
    width: 4px;
}

.flip-card-back::-webkit-scrollbar-track {
    background: rgba(201, 169, 98, 0.1);
    border-radius: 2px;
}

.flip-card-back::-webkit-scrollbar-thumb {
    background: rgba(201, 169, 98, 0.4);
    border-radius: 2px;
}

.flip-card-back::-webkit-scrollbar-thumb:hover {
    background: rgba(201, 169, 98, 0.6);
}

/* Active nav link styling */
.nav-link.active,
.mobile-nav-link.active {
    color: var(--gold-primary);
}

.nav-link.active::after {
    width: 100%;
}
