/* public_html/fontstore/assets/style.css - RESPONSIVE PREMIUM VERSION */
@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@300;400;600;800&display=swap');

:root {
    --bg-color: #ffffff;
    --text-main: #111111;
    --text-sec: #666666;
    --accent: #FF6B35;
    --accent-hover: #E85A25;
    --accent-light: #FFF4EE;
    --accent-glow: rgba(255, 107, 53, 0.15);
    --border: #eeeeee;
    --card-bg: #f9fafb;
    --header-h: 70px;
}

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Manrope', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--text-main);
    background: var(--bg-color);
    margin: 0;
    padding: 0;
    padding-top: var(--header-h);
    line-height: 1.5;
    overflow-x: hidden;
}

/* TYPOGRAPHY */
h1,
h2,
h3,
h4 {
    margin: 0;
    font-weight: 800;
    letter-spacing: -0.02em;
}

p {
    margin: 0 0 1rem;
    color: var(--text-sec);
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s;
}

/* UTILITY */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    background: var(--accent);
    color: white;
    font-weight: 700;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.2s;
    box-shadow: 0 2px 8px var(--accent-glow);
}

.btn:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px var(--accent-glow);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--border);
    color: var(--text-main);
    box-shadow: none;
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
    box-shadow: none;
}

.btn-full {
    width: 100%;
}

/* ===========================
   HEADER
   =========================== */
.main-header {
    height: var(--header-h);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    z-index: 1000;
    display: flex;
    align-items: center;
    padding: 0 2rem;
}

.main-header>.logo {
    flex-shrink: 0;
    text-align: left;
}

.main-header>.nav-links {
    flex: 2;
    display: flex;
    justify-content: center;
    margin: 0;
}

.main-header>.header-actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 1rem;
}

.logo {
    font-size: 1.5rem;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.nav-links a {
    margin-left: 2rem;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-sec);
}

.nav-links a:hover {
    color: var(--text-main);
}

/* Mobile Menu Toggle - hidden on desktop */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    color: var(--text-main);
}

/* Mobile Search Button - hidden on desktop */
.mobile-search-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    color: var(--text-main);
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s;
}

.mobile-search-btn:hover {
    background: #f0f0f0;
}

/* Mobile Search Overlay */
.mobile-search-overlay {
    display: none;
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    background: #fff;
    z-index: 998;
    padding: 1rem 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-100%);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.mobile-search-overlay.open {
    display: block;
    transform: translateY(0);
    opacity: 1;
}

.mobile-search-overlay .search-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.mobile-search-overlay .search-input-wrap input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 2.5rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
    outline: none;
    font-size: 1rem;
    font-family: inherit;
}

.mobile-search-overlay .search-input-wrap input:focus {
    background: #fff;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.mobile-search-close {
    position: absolute;
    right: 0.5rem;
    background: none;
    border: none;
    cursor: pointer;
    color: #94a3b8;
    padding: 0.25rem;
}

.mobile-search-overlay .search-results-dropdown {
    position: relative;
    top: 0.5rem;
    border-radius: 12px;
    max-height: 60vh;
    overflow-y: auto;
}

.mobile-search-overlay .search-results-dropdown.active {
    display: block;
}

.cart-icon-wrap {
    position: relative;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s;
    flex-shrink: 0;
}

.cart-icon-wrap:hover {
    background: #f0f0f0;
}

.cart-count {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--accent);
    color: white;
    font-size: 10px;
    font-weight: bold;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid white;
}

/* ===========================
   HERO
   =========================== */
.hero {
    padding: 8rem 0 6rem;
    text-align: center;
    background: radial-gradient(ellipse at 50% 0%, var(--accent-light) 0%, #ffffff 70%);
}

.hero h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.hero p {
    font-size: 1.25rem;
    max-width: 600px;
    margin: 0 auto 2rem;
}

/* ===========================
   PRODUCT GRID
   =========================== */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 2rem;
}

.card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease;
    position: relative;
    border: 1px solid transparent;
}

.card:hover {
    transform: translateY(-4px);
    border-color: var(--border);
    box-shadow: 0 10px 30px rgba(255, 107, 53, 0.08);
}

.card-img-box {
    aspect-ratio: 1/1;
    background: #f3f4f6;
    position: relative;
    overflow: hidden;
}

.card-img-box img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.5s ease;
}

.card:hover .card-img-box img:first-child {
    transform: scale(1.05);
}

.card-details {
    padding: 1.5rem 1rem;
    text-align: center;
}

.card-title {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    color: var(--text-main);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 0 10px;
}

.card-price {
    font-weight: 700;
    color: var(--text-main);
}

/* ===========================
   PRODUCT DETAIL PAGE (PDP)
   =========================== */
.pdp-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    padding: 4rem 0;
    align-items: start;
    margin-top: 1rem;
}

.pdp-left-col {
    position: sticky;
    top: calc(var(--header-h) + 1rem);
}

.pdp-img {
    background: #f3f4f6;
    border-radius: 16px;
    aspect-ratio: 1/1;
    position: relative;
    overflow: hidden;
    width: 100%;
}

.pdp-img img {
    display: block;
}

.pdp-content h1 {
    font-size: 1.8rem;
    line-height: 1.3;
    margin-bottom: 1rem;
}

.pdp-price {
    font-size: 1.75rem;
    color: var(--text-main);
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.size-opt {
    display: inline-flex;
    width: 48px;
    height: 48px;
    border: 1px solid var(--border);
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.size-opt:hover,
.size-opt.active {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

/* Variant Opt (Product Page) */
.variant-opt {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.75rem;
    border: 1px solid #eee;
    border-radius: 0.5rem;
    background: #fff;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
    font-size: inherit;
}

.variant-opt.active {
    border: 2px solid var(--accent);
    background: var(--accent-light);
}

/* Gallery Thumbs */
.gallery-thumbs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
    margin-top: 1rem;
}

/* ===========================
   DRAWER (Cart)
   =========================== */
.drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.3);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
    z-index: 2000;
}

.drawer-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

.drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 420px;
    background: white;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 2010;
    padding: 2rem;
    display: flex;
    flex-direction: column;
}

.drawer-overlay.open .drawer {
    transform: translateX(0);
}

.cart-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    border-bottom: 1px solid var(--border);
}

.cart-item img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    background: #f3f4f6;
    border-radius: 8px;
    flex-shrink: 0;
}

/* ===========================
   CHECKOUT
   =========================== */
.checkout-page {
    max-width: 800px;
    margin: 4rem auto;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    font-weight: 700;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    color: var(--text-sec);
}

.form-control {
    width: 100%;
    padding: 0.85rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
}

.form-control:focus {
    outline: none;
    border-color: var(--text-main);
    box-shadow: 0 0 0 1px var(--text-main);
}

/* ===========================
   RESPONSIVE: TABLET (iPad)
   max-width: 1024px
   =========================== */
@media (max-width: 1024px) {
    :root {
        --header-h: 60px;
    }

    body {
        padding-top: var(--header-h);
    }

    .pdp-wrapper {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 2rem 0;
    }

    .pdp-left-col {
        position: static;
    }

    .hero h1 {
        font-size: 3rem;
    }

    .hero {
        padding: 5rem 0 4rem;
    }

    .grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 1.5rem;
    }

    /* --- HEADER TABLET/MOBILE --- */
    .main-header {
        padding: 0 1rem;
        height: var(--header-h);
        flex-wrap: nowrap;
        justify-content: space-between;
    }

    /* Left: hamburger */
    .mobile-menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        order: 1;
        margin-right: 0;
        flex-shrink: 0;
    }

    /* Center: logo */
    .main-header>.logo {
        font-size: 1.3rem;
        order: 2;
        flex: 1;
        text-align: center;
    }

    /* Right: search + cart */
    .main-header>.header-actions {
        order: 3;
        flex-shrink: 0;
        gap: 0.25rem !important;
    }

    /* Hide nav links (shown via hamburger) */
    .main-header>.nav-links {
        display: none;
        position: fixed;
        top: var(--header-h);
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: flex-start;
        padding: 2rem;
        z-index: 999;
    }

    .main-header>.nav-links.open {
        display: flex;
    }

    .nav-links a {
        margin: 0;
        padding: 1rem 0;
        font-size: 1.1rem;
        border-bottom: 1px solid #f1f5f9;
    }

    /* Hide desktop search, show mobile search icon */
    .header-search {
        display: none;
    }

    .mobile-search-btn {
        display: flex;
    }

    .pdp-content h1 {
        font-size: 1.5rem;
    }
}

/* ===========================
   RESPONSIVE: MOBILE
   max-width: 768px
   =========================== */
@media (max-width: 768px) {

    /* --- HERO MOBILE --- */
    .hero {
        padding: 4rem 0 3rem;
    }

    .hero h1 {
        font-size: 2rem;
        line-height: 1.2;
    }

    .hero p {
        font-size: 1rem;
    }

    .hero .btn {
        padding: 0.75rem 1.5rem;
        font-size: 0.9rem;
    }

    /* --- GRID MOBILE --- */
    .grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .card {
        border-radius: 10px;
    }

    .card-details {
        padding: 0.75rem 0.5rem;
    }

    .card-title {
        font-size: 0.8rem;
        padding: 0 4px;
    }

    .card-price {
        font-size: 0.85rem;
    }

    /* --- PDP MOBILE --- */
    .pdp-wrapper {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 1.5rem 0;
        margin-top: 0;
    }

    .pdp-left-col {
        position: static;
    }

    .pdp-img {
        border-radius: 12px;
    }

    .pdp-content h1 {
        font-size: 1.3rem;
        line-height: 1.3;
    }

    .pdp-price {
        font-size: 1.4rem;
        margin-bottom: 1rem;
    }

    .gallery-thumbs {
        grid-template-columns: repeat(4, 1fr);
        gap: 0.4rem;
    }

    .size-opt {
        width: 42px;
        height: 42px;
        font-size: 0.85rem;
    }

    .variant-opt img {
        width: 28px !important;
        height: 28px !important;
    }

    .variant-opt span {
        font-size: 0.75rem !important;
    }

    /* --- DRAWER MOBILE --- */
    .drawer {
        width: 100%;
        padding: 1.5rem;
    }

    /* --- FOOTER MOBILE --- */
    footer {
        padding: 2rem 0 !important;
        margin-top: 3rem !important;
    }

    footer .container>div:first-child {
        grid-template-columns: 1fr !important;
        gap: 1.5rem !important;
    }

    /* --- CONTAINER --- */
    .container {
        padding: 0 1rem;
    }

    /* --- CHECKOUT MOBILE --- */
    .checkout-page {
        margin: 2rem auto;
    }
}

/* ===========================
   RESPONSIVE: SMALL MOBILE
   max-width: 480px
   =========================== */
@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.6rem;
    }

    .hero p {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
    }

    .hero {
        padding: 3rem 0 2rem;
    }

    .hero .btn {
        padding: 0.7rem 1.2rem;
        font-size: 0.85rem;
    }

    .pdp-content h1 {
        font-size: 1.15rem;
    }

    .pdp-price {
        font-size: 1.25rem;
    }

    .grid {
        gap: 0.5rem;
    }

    .card-details {
        padding: 0.5rem 0.25rem;
    }

    .card-title {
        font-size: 0.75rem;
    }

    .card-price {
        font-size: 0.8rem;
    }
}