/* Talabat Number Layout Styles
   Class prefix: w39df-
   Color palette: #BDC3C7 | #708090 | #20B2AA | #0E1621 | #FF8000
   Deep colors: backgrounds | Light colors: text
*/

:root {
    --w39df-primary: #20B2AA;
    --w39df-secondary: #708090;
    --w39df-accent: #FF8000;
    --w39df-dark: #0E1621;
    --w39df-light: #BDC3C7;
    --w39df-bg: #0E1621;
    --w39df-bg-light: #162230;
    --w39df-bg-card: #1A2B3D;
    --w39df-text: #E8ECF0;
    --w39df-text-muted: #BDC3C7;
    --w39df-border: #2A3F55;
    --w39df-gradient: linear-gradient(135deg, #0E1621 0%, #1A2B3D 50%, #162230 100%);
    --w39df-radius: 0.8rem;
    --w39df-radius-sm: 0.4rem;
    --w39df-radius-lg: 1.2rem;
    --w39df-shadow: 0 4px 16px rgba(0,0,0,0.35);
    --w39df-shadow-accent: 0 4px 20px rgba(255,128,0,0.25);
    --w39df-transition: all 0.3s ease;
}

/* Reset & Base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 62.5%; scroll-behavior: smooth; }
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--w39df-bg);
    color: var(--w39df-text);
    line-height: 1.6;
    font-size: 1.5rem;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
a { color: var(--w39df-primary); text-decoration: none; transition: var(--w39df-transition); }
a:hover { color: var(--w39df-accent); }
img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }

/* Container */
.w39df-container { max-width: 430px; margin: 0 auto; padding: 0 1.2rem; }
.w39df-wrapper { width: 100%; position: relative; }

/* Header */
.w39df-header {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    background: rgba(14,22,33,0.96);
    border-bottom: 2px solid var(--w39df-primary);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 0 1rem;
    height: 56px;
}
.w39df-header-inner {
    display: flex; align-items: center; justify-content: space-between;
    max-width: 430px; margin: 0 auto; height: 100%;
}
.w39df-logo-area { display: flex; align-items: center; gap: 0.8rem; }
.w39df-logo-area img { width: 30px; height: 30px; border-radius: 6px; }
.w39df-logo-area span { font-size: 1.6rem; font-weight: 700; color: var(--w39df-primary); letter-spacing: 0.5px; }
.w39df-header-actions { display: flex; gap: 0.6rem; align-items: center; }
.w39df-btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 0.7rem 1.4rem; border-radius: var(--w39df-radius-sm);
    font-size: 1.2rem; font-weight: 700; cursor: pointer;
    border: none; transition: var(--w39df-transition);
    text-transform: uppercase; letter-spacing: 0.3px;
    min-height: 36px;
}
.w39df-btn-register {
    background: var(--w39df-accent); color: #fff;
    box-shadow: var(--w39df-shadow-accent);
}
.w39df-btn-register:hover { background: #e67300; transform: scale(1.04); }
.w39df-btn-login {
    background: transparent; color: var(--w39df-primary);
    border: 1.5px solid var(--w39df-primary);
}
.w39df-btn-login:hover { background: var(--w39df-primary); color: var(--w39df-dark); }

/* Menu Toggle */
.w39df-menu-toggle {
    background: none; border: none; color: var(--w39df-text);
    font-size: 2.2rem; cursor: pointer; padding: 0.4rem;
    display: flex; align-items: center; justify-content: center;
}

/* Mobile Menu */
.w39df-mobile-menu {
    position: fixed; top: 0; right: -280px; width: 280px; height: 100%;
    background: var(--w39df-bg-light); z-index: 9999;
    transition: right 0.35s cubic-bezier(0.4,0,0.2,1);
    padding: 2rem 1.5rem; overflow-y: auto;
    border-left: 2px solid var(--w39df-primary);
}
.w39df-menu-active { right: 0 !important; }
.w39df-menu-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.6); z-index: 9998;
    opacity: 0; pointer-events: none; transition: opacity 0.35s ease;
}
.w39df-overlay-active { opacity: 1; pointer-events: auto; }
.w39df-menu-close {
    background: none; border: none; color: var(--w39df-text);
    font-size: 2.4rem; cursor: pointer; position: absolute;
    top: 1rem; right: 1rem;
}
.w39df-menu-title {
    font-size: 1.8rem; font-weight: 700; color: var(--w39df-primary);
    margin-bottom: 1.5rem; padding-bottom: 1rem;
    border-bottom: 1px solid var(--w39df-border);
}
.w39df-menu-link {
    display: block; padding: 1rem 0; color: var(--w39df-text-muted);
    font-size: 1.4rem; border-bottom: 1px solid var(--w39df-border);
    transition: var(--w39df-transition);
}
.w39df-menu-link:hover { color: var(--w39df-accent); padding-left: 0.8rem; }

/* Bottom Navigation */
.w39df-bottom-nav {
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 1000;
    background: linear-gradient(180deg, #162230 0%, #0E1621 100%);
    border-top: 2px solid var(--w39df-border);
    display: flex; justify-content: space-around; align-items: center;
    height: 60px; padding: 0 0.3rem;
}
.w39df-bottom-nav-btn {
    display: flex; flex-direction: column; align-items: center;
    justify-content: center; min-width: 60px; min-height: 52px;
    background: none; border: none; color: var(--w39df-light);
    font-size: 1rem; cursor: pointer; transition: var(--w39df-transition);
    gap: 0.2rem; border-radius: 8px; padding: 0.3rem;
}
.w39df-bottom-nav-btn i, .w39df-bottom-nav-btn .material-icons {
    font-size: 22px; transition: var(--w39df-transition);
}
.w39df-bottom-nav-btn span { font-size: 0.95rem; font-weight: 500; }
.w39df-bottom-nav-btn:hover, .w39df-bottom-nav-btn.w39df-nav-active {
    color: var(--w39df-accent);
    background: rgba(255,128,0,0.12);
}
.w39df-bottom-nav-btn.w39df-nav-active i,
.w39df-bottom-nav-btn.w39df-nav-active .material-icons {
    color: var(--w39df-accent);
    transform: scale(1.15);
}

/* Main content spacing for fixed navs */
main { padding-top: 56px; }
@media (max-width: 768px) {
    main { padding-bottom: 80px; }
}

/* Carousel */
.w39df-carousel { position: relative; width: 100%; overflow: hidden; border-radius: var(--w39df-radius); margin-bottom: 2rem; }
.w39df-carousel-track { display: flex; transition: transform 0.5s ease; }
.w39df-slide {
    min-width: 100%; position: relative; cursor: pointer;
    opacity: 0.6; transition: opacity 0.4s ease;
}
.w39df-slide-active { opacity: 1; }
.w39df-slide img { width: 100%; height: 200px; object-fit: cover; }
.w39df-slide-overlay {
    position: absolute; bottom: 0; left: 0; right: 0;
    background: linear-gradient(transparent, rgba(14,22,33,0.9));
    padding: 1.2rem;
}
.w39df-slide-title { font-size: 1.5rem; font-weight: 700; color: #fff; }
.w39df-carousel-dots {
    display: flex; justify-content: center; gap: 0.5rem;
    margin-top: 0.8rem;
}
.w39df-dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--w39df-secondary); cursor: pointer;
    transition: var(--w39df-transition); border: none;
}
.w39df-dot-active { background: var(--w39df-accent); width: 20px; border-radius: 4px; }

/* Sections */
.w39df-section { margin-bottom: 2.5rem; }
.w39df-section-title {
    font-size: 1.8rem; font-weight: 700; color: var(--w39df-text);
    margin-bottom: 1.2rem; padding-bottom: 0.8rem;
    border-bottom: 2px solid var(--w39df-primary);
    display: flex; align-items: center; gap: 0.6rem;
}
.w39df-section-title i { color: var(--w39df-accent); font-size: 2rem; }

/* Game Grid */
.w39df-game-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.8rem;
}
.w39df-game-item {
    background: var(--w39df-bg-card);
    border-radius: var(--w39df-radius);
    overflow: hidden; cursor: pointer;
    transition: var(--w39df-transition);
    border: 1px solid var(--w39df-border);
}
.w39df-game-item:hover {
    transform: translateY(-3px);
    border-color: var(--w39df-primary);
    box-shadow: 0 6px 20px rgba(32,178,170,0.2);
}
.w39df-game-img {
    width: 100%; aspect-ratio: 1; object-fit: cover;
    border-bottom: 1px solid var(--w39df-border);
}
.w39df-game-name {
    padding: 0.5rem 0.4rem; font-size: 1.1rem; font-weight: 600;
    color: var(--w39df-text); text-align: center;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    line-height: 1.3;
}

/* Category Tabs */
.w39df-cat-tabs { display: flex; gap: 0.6rem; margin-bottom: 1.5rem; flex-wrap: wrap; }
.w39df-cat-tab {
    padding: 0.6rem 1.2rem; border-radius: 2rem;
    font-size: 1.2rem; font-weight: 600; cursor: pointer;
    background: var(--w39df-bg-card); color: var(--w39df-light);
    border: 1px solid var(--w39df-border); transition: var(--w39df-transition);
}
.w39df-cat-tab-active, .w39df-cat-tab:hover {
    background: var(--w39df-primary); color: var(--w39df-dark);
    border-color: var(--w39df-primary);
}

/* Cards */
.w39df-card {
    background: var(--w39df-bg-card); border-radius: var(--w39df-radius);
    padding: 1.5rem; margin-bottom: 1.5rem;
    border: 1px solid var(--w39df-border);
    transition: var(--w39df-transition);
}
.w39df-card:hover { border-color: var(--w39df-primary); }
.w39df-card-title {
    font-size: 1.6rem; font-weight: 700; margin-bottom: 0.8rem;
    color: var(--w39df-primary);
}
.w39df-card-text { font-size: 1.3rem; line-height: 1.7; color: var(--w39df-text-muted); }

/* Promo Banner */
.w39df-promo-banner {
    background: linear-gradient(135deg, var(--w39df-accent) 0%, #FF9933 100%);
    border-radius: var(--w39df-radius-lg); padding: 1.5rem 1.2rem;
    text-align: center; margin-bottom: 2rem; cursor: pointer;
    box-shadow: var(--w39df-shadow-accent);
    transition: var(--w39df-transition);
}
.w39df-promo-banner:hover { transform: scale(1.02); }
.w39df-promo-banner h3 { font-size: 1.8rem; color: #fff; font-weight: 800; margin-bottom: 0.4rem; }
.w39df-promo-banner p { font-size: 1.3rem; color: rgba(255,255,255,0.9); }

/* Feature List */
.w39df-feature-list { display: flex; flex-direction: column; gap: 1rem; }
.w39df-feature-item {
    display: flex; gap: 1rem; align-items: flex-start;
    padding: 1rem; background: var(--w39df-bg-light);
    border-radius: var(--w39df-radius-sm);
    border-left: 3px solid var(--w39df-accent);
}
.w39df-feature-item i { color: var(--w39df-accent); font-size: 2rem; min-width: 28px; }
.w39df-feature-item p { font-size: 1.3rem; color: var(--w39df-text-muted); }

/* Testimonial */
.w39df-testimonial {
    background: var(--w39df-bg-light); border-radius: var(--w39df-radius);
    padding: 1.2rem; margin-bottom: 1rem;
    border-left: 3px solid var(--w39df-primary);
}
.w39df-testimonial-text { font-size: 1.3rem; color: var(--w39df-text-muted); font-style: italic; margin-bottom: 0.5rem; }
.w39df-testimonial-author { font-size: 1.1rem; color: var(--w39df-accent); font-weight: 600; }

/* Payment icons row */
.w39df-payment-row { display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; margin: 1rem 0; }
.w39df-payment-item {
    background: var(--w39df-bg-light); border-radius: var(--w39df-radius-sm);
    padding: 0.8rem 1.2rem; font-size: 1.2rem; color: var(--w39df-primary);
    font-weight: 600; border: 1px solid var(--w39df-border);
}

/* Winner item */
.w39df-winner {
    display: flex; justify-content: space-between; align-items: center;
    padding: 0.8rem 1rem; background: var(--w39df-bg-light);
    border-radius: var(--w39df-radius-sm); margin-bottom: 0.5rem;
}
.w39df-winner-name { font-size: 1.2rem; color: var(--w39df-primary); font-weight: 600; }
.w39df-winner-amount { font-size: 1.3rem; color: var(--w39df-accent); font-weight: 700; }

/* Promo text link */
.w39df-promo-text {
    color: var(--w39df-accent); font-weight: 700; cursor: pointer;
    text-decoration: underline; transition: var(--w39df-transition);
}
.w39df-promo-text:hover { color: #FF9933; }

/* Footer */
.w39df-footer {
    background: var(--w39df-bg-light); border-top: 2px solid var(--w39df-border);
    padding: 2rem 1.2rem 1rem; margin-top: 3rem;
}
.w39df-footer-brand {
    font-size: 1.5rem; font-weight: 700; color: var(--w39df-primary);
    margin-bottom: 1rem;
}
.w39df-footer-desc { font-size: 1.2rem; color: var(--w39df-text-muted); line-height: 1.6; margin-bottom: 1.5rem; }
.w39df-footer-links { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-bottom: 1.5rem; }
.w39df-footer-link {
    padding: 0.5rem 1rem; background: var(--w39df-bg-card);
    border-radius: var(--w39df-radius-sm); color: var(--w39df-primary);
    font-size: 1.1rem; border: 1px solid var(--w39df-border);
    transition: var(--w39df-transition);
}
.w39df-footer-link:hover { border-color: var(--w39df-primary); color: var(--w39df-accent); }
.w39df-footer-copy {
    text-align: center; font-size: 1.1rem; color: var(--w39df-secondary);
    padding-top: 1rem; border-top: 1px solid var(--w39df-border);
}

/* FAQ Accordion */
.w39df-faq-item {
    background: var(--w39df-bg-card); border-radius: var(--w39df-radius);
    margin-bottom: 0.8rem; border: 1px solid var(--w39df-border);
    overflow: hidden;
}
.w39df-faq-q {
    padding: 1rem 1.2rem; font-size: 1.3rem; font-weight: 700;
    color: var(--w39df-text); cursor: pointer;
    display: flex; justify-content: space-between; align-items: center;
}
.w39df-faq-q i { color: var(--w39df-accent); font-size: 1.4rem; }
.w39df-faq-a { padding: 0 1.2rem 1rem; font-size: 1.2rem; color: var(--w39df-text-muted); line-height: 1.7; }

/* Content sections */
.w39df-content-block { margin-bottom: 2rem; }
.w39df-content-block h2 {
    font-size: 1.7rem; color: var(--w39df-primary); font-weight: 700;
    margin-bottom: 0.8rem; padding-left: 0.8rem;
    border-left: 3px solid var(--w39df-accent);
}
.w39df-content-block h3 {
    font-size: 1.5rem; color: var(--w39df-accent); font-weight: 600;
    margin: 1rem 0 0.5rem;
}
.w39df-content-block p {
    font-size: 1.3rem; color: var(--w39df-text-muted); line-height: 1.8;
    margin-bottom: 0.8rem;
}
.w39df-content-block ul { padding-left: 1.5rem; }
.w39df-content-block li {
    font-size: 1.3rem; color: var(--w39df-text-muted);
    line-height: 1.7; margin-bottom: 0.4rem;
    list-style: disc;
}

/* Back to top */
.w39df-back-top {
    position: fixed; bottom: 72px; right: 1rem; z-index: 999;
    background: var(--w39df-primary); color: #fff; border: none;
    width: 40px; height: 40px; border-radius: 50%;
    font-size: 1.6rem; cursor: pointer; display: none;
    align-items: center; justify-content: center;
    box-shadow: var(--w39df-shadow);
}
.w39df-back-top:hover { background: var(--w39df-accent); }

/* Desktop: hide bottom nav */
@media (min-width: 769px) {
    .w39df-bottom-nav { display: none; }
    .w39df-container { max-width: 430px; }
}
