/* =====================
   FLazy Homepage CSS
   Light Auth / Dashboard Style
===================== */

:root {
    --primary: #2f36ff;
    --primary-light: #7c83ff;
    --purple: #7c3aed;
    --purple-light: #a78bfa;
    --navy: #062b55;

    --bg: #f7f7fb;
    --card: #ffffff;
    --soft: #f1f2f6;
    --soft2: #f8f8ff;

    --border: #e5e7eb;
    --text: #111827;
    --text-muted: #6b7280;
    --text-light: #9ca3af;

    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;

    --shadow: 0 12px 35px rgba(15, 23, 42, 0.08);
    --shadow2: 0 20px 55px rgba(15, 23, 42, 0.12);
    --glow: 0 0 0 3px rgba(47, 54, 255, 0.12), 0 0 18px rgba(47, 54, 255, 0.22);

    --radius: 22px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: Arial, "Noto Sans SC", sans-serif;
    background:
        radial-gradient(circle at top left, rgba(124,58,237,0.10), transparent 35%),
        radial-gradient(circle at bottom right, rgba(47,54,255,0.08), transparent 38%),
        var(--bg);
    color: var(--text);
    line-height: 1.7;
    overflow-x: hidden;
}

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

button,
input {
    font-family: Arial, "Noto Sans SC", sans-serif;
}

img {
    max-width: 100%;
}

/* =====================
   NAVBAR
===================== */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 200;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 42px;
    background: #ffffff;
    border-bottom: 1px solid rgba(229,231,235,0.9);
    box-shadow: 0 4px 18px rgba(15,23,42,0.06);
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.nav-logo-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--purple), var(--purple-light));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 900;
    box-shadow: 0 0 25px rgba(124,58,237,0.28);
}

.nav-logo-text {
    font-size: 1.55rem;
    font-weight: 900;
    color: var(--text);
}

.nav-center {
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-center a {
    color: var(--text-muted);
    font-weight: 800;
    font-size: 0.9rem;
    padding: 7px 14px;
    border-radius: 999px;
    transition: all 0.2s;
}

.nav-center a:hover {
    background: var(--soft);
    color: var(--text);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.nav-auth-link,
.nav-btn-register {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--navy);
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 999px;
    font-weight: 900;
    font-size: 0.9rem;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(6,43,85,0.22);
    transition: all 0.25s;
    white-space: nowrap;
}

.nav-auth-link:hover,
.nav-btn-register:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(6,43,85,0.28);
}

.desktop-user-pill {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 5px 16px 5px 5px;
    box-shadow: 0 8px 22px rgba(15,23,42,0.06);
    max-width: 260px;
    transition: all 0.25s;
}

.desktop-user-pill:hover {
    border-color: rgba(47,54,255,0.28);
    box-shadow: var(--glow);
    transform: translateY(-1px);
}

.desktop-user-avatar-wrap {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
}

.desktop-user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    display: none;
    border: 2px solid var(--purple);
}

.desktop-user-fallback {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--purple), var(--purple-light));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.desktop-user-name {
    font-size: 0.86rem;
    font-weight: 900;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nav-hamburger {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid var(--border);
    border-radius: 14px;
    background: #ffffff;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(15,23,42,0.06);
}

.nav-hamburger span {
    display: block;
    width: 18px;
    height: 2px;
    background: var(--text);
    border-radius: 99px;
    margin: 5px auto;
}

/* =====================
   MOBILE MENU
===================== */

.mobile-menu {
    position: fixed;
    top: 76px;
    left: 18px;
    right: 18px;
    z-index: 190;
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 18px;
    box-shadow: var(--shadow2);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-12px);
    transition: all 0.25s;
}

.mobile-menu.open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.mobile-link {
    display: block;
    color: var(--text-muted);
    font-weight: 900;
    padding: 14px 20px;
    border-radius: 14px;
}

.mobile-link:hover {
    background: var(--soft);
    color: var(--text);
}

.mobile-auth-btns {
    margin-top: 12px;
    display: grid;
    grid-template-columns: 1fr;
}

.mobile-auth-btns .nav-auth-link {
    width: 100%;
}

.mobile-user-info {
    margin-top: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--soft2);
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 12px;
}

.mobile-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    object-fit: cover;
    display: none;
    border: 2px solid var(--purple);
    flex-shrink: 0;
}

.mobile-user-fallback {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--purple), var(--purple-light));
    color: white;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.mobile-user-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.mobile-username {
    font-weight: 900;
    color: var(--text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mobile-user-text a {
    font-size: 0.78rem;
    color: var(--purple);
    font-weight: 800;
}

/* =====================
   HERO
===================== */

.hero {
    min-height: 100vh;
    padding: 120px 40px 80px;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 12% 28%, rgba(124,58,237,0.15), transparent 36%),
        radial-gradient(circle at 80% 70%, rgba(245,158,11,0.08), transparent 38%);
    pointer-events: none;
}

.hero-inner {
    position: relative;
    z-index: 1;
    max-width: 1280px;
    margin: 0 auto;
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 70px;
    align-items: center;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(124,58,237,0.10);
    border: 1px solid rgba(124,58,237,0.24);
    color: var(--purple);
    padding: 7px 16px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 900;
    margin-bottom: 24px;
}

.hero-badge span {
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: 50%;
    box-shadow: 0 0 0 5px rgba(16,185,129,0.14);
}

.hero-title {
    font-weight: 900;
    font-size: clamp(2.4rem, 5vw, 4.5rem);
    line-height: 1.08;
    letter-spacing: -2px;
    color: var(--text);
    margin-bottom: 22px;
}

.hero-highlight,
.hero-title span {
    background: linear-gradient(135deg, var(--purple), var(--primary-light), var(--warning));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-sub {
    max-width: 560px;
    color: var(--text-muted);
    font-size: 1.03rem;
    line-height: 1.8;
    margin-bottom: 24px;
}

.hero-trust-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 34px;
}

.trust-badge-item {
    background: white;
    border: 1px solid var(--border);
    color: var(--text-muted);
    padding: 8px 14px;
    border-radius: 999px;
    font-weight: 800;
    font-size: 0.82rem;
    box-shadow: 0 8px 22px rgba(15,23,42,0.05);
}

.hero-actions {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.btn-hero-primary,
.btn-hero-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 30px;
    border-radius: 999px;
    font-weight: 900;
    transition: all 0.25s;
}

.btn-hero-primary {
    background: var(--navy);
    color: white;
    box-shadow: 0 10px 25px rgba(6,43,85,0.22);
}

.btn-hero-secondary {
    background: white;
    color: var(--text);
    border: 1px solid var(--border);
    box-shadow: 0 10px 25px rgba(15,23,42,0.06);
}

.btn-hero-primary:hover,
.btn-hero-secondary:hover {
    transform: translateY(-2px);
}

/* =====================
   SERVICE HUB
===================== */

.service-hub-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: 28px;
    padding: 28px;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.service-hub-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 4px;
    background: linear-gradient(90deg, var(--purple), var(--primary-light), var(--warning));
}

.hub-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}

.hub-label {
    color: var(--text-light);
    font-size: 0.82rem;
    font-weight: 900;
}

.hub-top h2 {
    font-size: 1.25rem;
    margin-top: 2px;
}

.hub-status {
    color: #059669;
    background: rgba(16,185,129,0.10);
    border: 1px solid rgba(16,185,129,0.22);
    padding: 6px 13px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 900;
}

.hub-item {
    display: flex;
    align-items: center;
    gap: 14px;
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 15px;
    margin-top: 10px;
    transition: all 0.22s;
}

.hub-item:hover {
    background: var(--soft2);
    border-color: rgba(47,54,255,0.25);
    transform: translateX(4px);
}

.hub-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    flex-shrink: 0;
}

.hub-icon.purple {
    background: rgba(124,58,237,0.13);
    color: var(--purple);
}

.hub-icon.green {
    background: rgba(16,185,129,0.10);
    color: #059669;
}

.hub-icon.blue {
    background: rgba(47,54,255,0.10);
    color: var(--primary);
}

.hub-icon.amber {
    background: rgba(245,158,11,0.12);
    color: #d97706;
}

.hub-info {
    flex: 1;
    min-width: 0;
}

.hub-info strong {
    display: block;
    font-size: 0.92rem;
}

.hub-info span {
    display: block;
    color: var(--text-muted);
    font-size: 0.78rem;
}

.hub-price {
    color: #059669;
    font-weight: 900;
    white-space: nowrap;
}

/* =====================
   TRUST SECTION
===================== */

.trust-section {
    padding: 54px 0;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 40px;
}

.trust-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}

.trust-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 26px;
    text-align: center;
    box-shadow: 0 10px 28px rgba(15,23,42,0.05);
    transition: all 0.25s;
}

.trust-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.trust-icon {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    background: rgba(124,58,237,0.10);
    color: var(--purple);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    font-size: 1.1rem;
}

.trust-name {
    font-weight: 900;
    margin-bottom: 4px;
}

.trust-desc {
    color: var(--text-muted);
    font-size: 0.82rem;
}

/* =====================
   SECTIONS / PRODUCTS
===================== */

.service-section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 46px;
}

.section-tag {
    display: inline-block;
    background: rgba(124,58,237,0.10);
    border: 1px solid rgba(124,58,237,0.22);
    color: var(--purple);
    padding: 5px 15px;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 900;
    margin-bottom: 14px;
}

.section-title {
    font-size: clamp(1.8rem, 3vw, 2.7rem);
    font-weight: 900;
    margin-bottom: 10px;
}

.section-sub {
    color: var(--text-muted);
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.product-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: 26px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 28px rgba(15,23,42,0.05);
    transition: all 0.3s;
    opacity: 0;
    transform: translateY(26px);
}

.product-card.fade-in {
    opacity: 1;
    transform: translateY(0);
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow);
    border-color: rgba(47,54,255,0.25);
}

.product-tag {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 2;
    background: linear-gradient(135deg, var(--warning), #ef4444);
    color: white;
    padding: 5px 13px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 900;
}

.product-image-container {
    height: 160px;
    background:
        radial-gradient(circle at top left, rgba(124,58,237,0.35), transparent 35%),
        linear-gradient(135deg, #050816, #062b55);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.product-image-text {
    color: white;
    font-size: 1.25rem;
    font-weight: 900;
    text-align: center;
}

.product-code {
    position: absolute;
    left: 16px;
    bottom: 14px;
    background: rgba(255,255,255,0.14);
    border: 1px solid rgba(255,255,255,0.18);
    color: white;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 900;
}

.product-content {
    padding: 24px;
}

.product-content h3 {
    font-size: 1.1rem;
    font-weight: 900;
    margin-bottom: 10px;
}

.product-description {
    color: var(--text-muted);
    font-size: 0.88rem;
    margin-bottom: 14px;
}

.features {
    list-style: none;
    margin-bottom: 18px;
}

.features li {
    color: var(--text-muted);
    font-size: 0.86rem;
    margin-bottom: 8px;
    padding-left: 22px;
    position: relative;
}

.features li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--success);
    font-weight: 900;
}

.buy-btn {
    display: block;
    width: 100%;
    text-align: center;
    background: var(--navy);
    color: white;
    padding: 12px 18px;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 900;
    box-shadow: 0 8px 20px rgba(6,43,85,0.22);
    transition: all 0.25s;
}

.buy-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(6,43,85,0.28);
}

/* =====================
   FAQ
===================== */

.faq-section {
    padding: 80px 0;
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.faq-item {
    background: white;
    border: 1px solid var(--border);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 28px rgba(15,23,42,0.04);
}

.faq-question {
    padding: 18px 22px;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    cursor: pointer;
    font-weight: 900;
}

.toggle-icon {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: rgba(124,58,237,0.10);
    color: var(--purple);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    flex-shrink: 0;
    transition: all 0.25s;
}

.faq-item.active .toggle-icon {
    transform: rotate(45deg);
    background: var(--purple);
    color: white;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s;
}

.faq-answer p {
    color: var(--text-muted);
    padding: 0 22px 18px;
    font-size: 0.9rem;
}

/* =====================
   FLOATING BUTTONS
===================== */

.floating-actions {
    position: fixed;
    right: 22px;
    bottom: 24px;
    z-index: 500;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.floating-btn {
    width: 52px;
    height: 52px;
    border-radius: 18px;
    background: white;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--purple);
    font-size: 1.25rem;
    cursor: pointer;
    box-shadow: var(--shadow);
    transition: all 0.25s;
}

.floating-btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow2);
}

.floating-btn:first-child {
    color: #25d366;
}

.back-to-top {
    opacity: 0;
    pointer-events: none;
    transform: translateY(8px);
}

.back-to-top.show {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

/* =====================
   FOOTER
===================== */

footer {
    background: white;
    border-top: 1px solid var(--border);
    text-align: center;
    padding: 36px 40px;
}

.footer-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    font-weight: 900;
    margin-bottom: 12px;
}

.footer-logo-icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--purple), var(--purple-light));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
}

footer p {
    color: var(--text-muted);
    font-size: 0.86rem;
}

.footer-disclaimer {
    max-width: 760px;
    margin: 8px auto 0;
    font-size: 0.78rem;
}

footer nav {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-top: 18px;
    flex-wrap: wrap;
}

footer nav a {
    color: var(--text-muted);
    font-weight: 800;
    font-size: 0.86rem;
}

footer nav a:hover {
    color: var(--purple);
}

/* =====================
   DESKTOP FIX
===================== */

@media (min-width: 1081px) {
    .nav-center {
        display: flex !important;
    }

    .nav-right {
        display: flex;
    }

    .nav-hamburger {
        display: none !important;
    }

    .mobile-menu {
        display: none !important;
    }

    #navGuestBox,
    #navUserBox {
        align-items: center;
    }

    .desktop-user-pill {
       display: inline-flex !important;
   }
}

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

@media (max-width: 1080px) {
    .nav-center,
    #navGuestBox,
    #navUserBox {
        display: none !important;
    }

    .nav-hamburger {
        display: block;
    }

    .hero-inner {
        grid-template-columns: 1fr;
        gap: 42px;
    }

    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .trust-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 575px) {
    .navbar {
        height: 66px;
        padding: 0 18px;
    }

    .nav-logo-icon {
        width: 40px;
        height: 40px;
    }

    .nav-logo-text {
        font-size: 1.45rem;
    }

    .mobile-menu {
        top: 76px;
        left: 14px;
        right: 14px;
        border-radius: 22px;
    }

    .hero {
        padding: 96px 18px 56px;
        min-height: auto;
    }

    .hero-title {
        font-size: 2.35rem;
        letter-spacing: -1px;
    }

    .hero-sub {
        font-size: 0.95rem;
    }

    .hero-actions {
        flex-direction: column;
    }

    .btn-hero-primary,
    .btn-hero-secondary {
        width: 100%;
    }

    .service-hub-card {
        padding: 22px;
        border-radius: 24px;
    }

    .hub-item {
        align-items: flex-start;
    }

    .hub-price {
        font-size: 0.86rem;
    }

    .container {
        padding: 0 18px;
    }

    .trust-grid,
    .product-grid,
    .faq-grid {
        grid-template-columns: 1fr;
    }

    .service-section {
        padding: 58px 0;
    }

    .section-header {
        margin-bottom: 32px;
    }

    .product-image-container {
        height: 150px;
    }

    .floating-actions {
        right: 14px;
        bottom: 18px;
    }

    .floating-btn {
        width: 50px;
        height: 50px;
        border-radius: 16px;
    }

    footer {
        padding: 32px 18px 92px;
    }

    footer nav {
        gap: 18px;
    }
}

@media (min-width: 1081px) {
    #navUserBox {
        display: none;
    }

    #navUserBox.show {
        display: flex !important;
    }

    #navGuestBox.hide {
        display: none !important;
    }

    .desktop-user-pill {
        display: inline-flex !important;
        align-items: center;
        gap: 10px;
        background: #ffffff;
        border: 1px solid var(--border);
        border-radius: 999px;
        padding: 5px 16px 5px 5px;
        box-shadow: 0 8px 22px rgba(15,23,42,0.06);
        max-width: 260px;
    }

    .desktop-user-avatar-wrap {
        width: 32px;
        height: 32px;
        flex-shrink: 0;
    }

    .desktop-user-avatar,
    #navUserAvatar {
        width: 32px !important;
        height: 32px !important;
        border-radius: 50%;
        object-fit: cover;
        border: 2px solid var(--purple);
        display: none;
    }

    .desktop-user-fallback,
    #navUserFallback {
        width: 32px;
        height: 32px;
        border-radius: 50%;
        background: linear-gradient(135deg, var(--purple), var(--purple-light));
        color: white;
        display: flex;
        align-items: center;
        justify-content: center;
        font-weight: 900;
    }

    .desktop-user-name,
    #navUserName {
        font-size: 0.86rem;
        font-weight: 900;
        color: var(--text);
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}
