/* ============================================================
   HHPOKER - Western Cowboy Texas Poker Club
   Design: Western Red (#c2410c) + Cream (#fef3c7)
   Style: Rough western saloon, playing-card features
   ============================================================ */

/* === Google Font Import === */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;0,800;0,900;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

/* === CSS Variables === */
:root {
    --western: #c2410c;
    --western-light: #d45a2a;
    --western-dark: #9a3409;
    --western-deepest: #7a2805;
    --cream: #fef3c7;
    --cream-light: #fff9e6;
    --cream-dark: #f5d78c;
    --cream-deeper: #e8c46a;
    --saloon-wood: #5c3a1e;
    --saloon-dark: #3e2210;
    --saloon-tan: #d4a76a;
    --saloon-gold: #c9963e;
    --border-rough: 4px;
    --shadow-card: 8px 8px 0px rgba(62, 34, 16, 0.3);
    --shadow-card-hover: 12px 12px 0px rgba(62, 34, 16, 0.4);
}

/* === Base Styles === */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 5rem;
}

body {
    overflow-x: hidden;
}

/* === Selection === */
::selection {
    background-color: var(--western);
    color: var(--cream);
}

/* === Scrollbar === */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--saloon-dark);
}
::-webkit-scrollbar-thumb {
    background: var(--western);
    border-radius: 0;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--western-light);
}

/* ============================================================
   NAVBAR
   ============================================================ */
#navbar.scrolled {
    box-shadow: 0 4px 0px rgba(62, 34, 16, 0.4);
    background-color: var(--western-dark);
}

.nav-link {
    position: relative;
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: var(--cream);
    transition: width 0.3s ease;
}
.nav-link:hover::after {
    width: 60%;
}

/* === Mobile Menu Animation === */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
}
#mobile-menu.open {
    max-height: 500px;
}

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero-img-wrapper {
    position: relative;
    display: inline-block;
    border: 6px solid var(--cream);
    box-shadow: var(--shadow-card);
    transform: rotate(-1deg);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    overflow: hidden;
}
.hero-img-wrapper:hover {
    transform: rotate(0deg);
    box-shadow: var(--shadow-card-hover);
}
.hero-img {
    display: block;
    filter: sepia(0.15) contrast(1.05);
    transition: filter 0.4s ease;
}
.hero-img-wrapper:hover .hero-img {
    filter: sepia(0) contrast(1.1);
}

.rough-badge {
    transform: rotate(3deg);
    clip-path: polygon(0% 0%, 95% 0%, 100% 10%, 100% 100%, 5% 100%, 0% 90%);
    transition: transform 0.3s ease;
}
.rough-badge:hover {
    transform: rotate(0deg);
}

/* ============================================================
   POKER CARDS (Features Section)
   ============================================================ */
.poker-card {
    position: relative;
    background: #fffef9;
    border: 4px solid var(--saloon-tan);
    box-shadow: var(--shadow-card);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
    overflow: hidden;
}
.poker-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-card-hover);
}
.poker-card::before {
    content: '';
    position: absolute;
    inset: 8px;
    border: 2px dashed rgba(194, 65, 12, 0.12);
    pointer-events: none;
    z-index: 1;
}

/* Card inner (top section with suit) */
.poker-card-inner {
    position: relative;
    background: linear-gradient(135deg, #fef9f0 0%, #fffef9 40%, #fdf6e8 100%);
    padding: 28px 24px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 4px solid var(--western);
}

/* Corner suit icons */
.card-corner {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1;
}
.card-corner.top-left {
    top: 10px;
    left: 14px;
}
.card-corner.bottom-right {
    bottom: 10px;
    right: 14px;
    transform: rotate(180deg);
}
.card-corner .suit-icon {
    font-size: 1.6rem;
    color: #1a1a1a;
    font-weight: bold;
}
.card-corner .suit-icon.heart {
    color: var(--western);
}
.card-corner .suit-label {
    font-size: 1rem;
    font-weight: 900;
    color: #1a1a1a;
    font-family: 'Playfair Display', Georgia, serif;
    margin-top: -4px;
}

/* Center icon */
.card-center-icon {
    color: #1a1a1a;
    opacity: 0.2;
    transition: opacity 0.3s ease, transform 0.3s ease;
}
.poker-card:hover .card-center-icon {
    opacity: 0.35;
    transform: scale(1.1);
}
.heart-icon {
    color: var(--western);
}

/* Card content */
.poker-card-content {
    padding: 24px 20px 28px;
    position: relative;
    z-index: 2;
}

/* Data suit attribute variants */
.poker-card[data-suit="spade"] .poker-card-inner {
    border-bottom-color: #1a1a1a;
}
.poker-card[data-suit="heart"] .poker-card-inner {
    border-bottom-color: var(--western);
}
.poker-card[data-suit="club"] .poker-card-inner {
    border-bottom-color: #1a1a1a;
}

/* ============================================================
   STATS SECTION
   ============================================================ */
.stat-item {
    position: relative;
    transition: transform 0.3s ease, border-color 0.3s ease;
}
.stat-item:hover {
    transform: translateY(-4px);
    border-color: var(--cream-dark);
}
.stat-item::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 10%;
    width: 80%;
    height: 3px;
    background: var(--western);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}
.stat-item:hover::after {
    transform: scaleX(1);
}

/* === Counter Animation === */
.counter {
    display: inline-block;
    font-variant-numeric: tabular-nums;
}

/* ============================================================
   TESTIMONIALS
   ============================================================ */
.testimonial-card {
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
    position: relative;
}
.testimonial-card:hover {
    transform: translateY(-6px);
    box-shadow: 8px 8px 0px rgba(194, 65, 12, 0.25);
    border-color: var(--western);
}
.testimonial-card::after {
    content: '❞';
    position: absolute;
    bottom: 12px;
    right: 20px;
    font-size: 2.5rem;
    color: var(--western);
    opacity: 0.2;
    line-height: 1;
}

/* ============================================================
   FAQ ACCORDION
   ============================================================ */
.faq-item {
    transition: border-color 0.3s ease, background-color 0.3s ease;
}
.faq-item:hover {
    border-color: var(--cream-dark);
    background-color: rgba(254, 243, 199, 0.08);
}
.faq-item.active {
    border-color: var(--cream-dark);
    background-color: rgba(254, 243, 199, 0.1);
}

.faq-toggle {
    cursor: pointer;
    user-select: none;
    transition: color 0.3s ease;
}
.faq-toggle:hover {
    color: var(--cream);
}

.faq-toggle i.fa-chevron-down {
    transition: transform 0.3s ease;
}
.faq-item.active .faq-toggle i.fa-chevron-down {
    transform: rotate(180deg);
}

.faq-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
}
.faq-body.open {
    max-height: 400px;
}

/* ============================================================
   CTA SECTION
   ============================================================ */
#cta {
    background-image:
        radial-gradient(ellipse at 20% 50%, rgba(254, 243, 199, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 50%, rgba(254, 243, 199, 0.06) 0%, transparent 50%),
        linear-gradient(135deg, var(--western-deepest) 0%, var(--western) 40%, var(--western-light) 100%);
}
#cta a {
    position: relative;
    overflow: hidden;
}
#cta a::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0);
    transition: background 0.3s ease;
}
#cta a:hover::before {
    background: rgba(255, 255, 255, 0.05);
}

/* ============================================================
   FOOTER
   ============================================================ */
footer a:hover {
    text-decoration: underline;
}

/* ============================================================
   ANIMATIONS
   ============================================================ */

/* Fade-in-up on scroll */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger delays for grid children */
.stagger-1 { transition-delay: 0.05s; }
.stagger-2 { transition-delay: 0.15s; }
.stagger-3 { transition-delay: 0.25s; }
.stagger-4 { transition-delay: 0.35s; }

/* Pulse animation for CTA button */
@keyframes pulse-cta {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(254, 243, 199, 0.5);
    }
    50% {
        box-shadow: 0 0 0 18px rgba(254, 243, 199, 0);
    }
}
#cta a:first-child {
    animation: pulse-cta 2.5s infinite;
}

/* Rough border effect for sections */
.rough-border-section {
    border-style: solid;
    border-width: 4px;
    border-image: repeating-linear-gradient(
        0deg,
        var(--saloon-tan),
        var(--saloon-tan) 2px,
        transparent 2px,
        transparent 4px
    ) 4;
}

/* Playing card flip (subtle on hover) */
@media (min-width: 768px) {
    .poker-card {
        perspective: 1000px;
    }
}

/* ============================================================
   RESPONSIVE ADJUSTMENTS
   ============================================================ */
@media (max-width: 767px) {
    .hero-img-wrapper {
        border-width: 4px;
        box-shadow: 4px 4px 0px rgba(62, 34, 16, 0.3);
    }
    .rough-badge {
        font-size: 0.75rem;
        padding: 0.5rem 1rem;
        bottom: -10px;
        right: -10px;
        border-width: 3px;
    }
    .poker-card {
        box-shadow: 4px 4px 0px rgba(62, 34, 16, 0.3);
    }
    .poker-card-inner {
        padding: 20px 16px 14px;
    }
    .poker-card-content {
        padding: 16px 14px 20px;
    }
    .card-center-icon {
        font-size: 3rem !important;
    }
    .stat-item {
        padding: 1rem !important;
    }
    .stat-item .counter,
    .stat-item .font-western.text-4xl {
        font-size: 2rem !important;
    }
    .testimonial-card {
        border-width: 3px;
    }
}

@media (max-width: 480px) {
    #hero h1 {
        font-size: 1.75rem;
    }
    .card-corner .suit-icon {
        font-size: 1.2rem;
    }
    .card-corner .suit-label {
        font-size: 0.8rem;
    }
}

/* === Print styles (subtle) === */
@media print {
    #navbar, #mobile-menu {
        position: static;
    }
    .poker-card {
        break-inside: avoid;
    }
}
