/* =========================================================
   MICE 3D · v5.1.11 · COSMIC
   ========================================================= */
:root {
    --bg-deep: #030305;
    --bg-mid: #08080f;
    --glass-bg: rgba(255,255,255,0.03);
    --glass-bg-strong: rgba(12,12,22,0.92);
    --glass-border: rgba(255,255,255,0.06);
    --glass-border-strong: rgba(255,255,255,0.12);
    --accent: #6366f1;
    --accent-2: #8b5cf6;
    --accent-3: #d946ef;
    --accent-grad: linear-gradient(135deg, #6366f1, #8b5cf6 50%, #d946ef);
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #06b6d4;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --text-dim: #475569;
    --radius-sm: 12px;
    --radius-md: 18px;
    --radius-lg: 24px;
    --radius-xl: 32px;
    --shadow-sm: 0 4px 16px rgba(0,0,0,0.4);
    --shadow-md: 0 12px 32px rgba(0,0,0,0.5);
    --shadow-lg: 0 24px 64px rgba(0,0,0,0.6);
    --shadow-glow: 0 0 40px rgba(99,102,241,0.15);
    --t-fast: 0.15s cubic-bezier(0.4,0,0.2,1);
    --t-base: 0.3s cubic-bezier(0.4,0,0.2,1);
    --t-slow: 0.5s cubic-bezier(0.4,0,0.2,1);
}
* { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior: smooth; }
body {
    background: var(--bg-deep);
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: var(--text-main);
    min-height: 100vh; min-height: 100dvh;
    line-height: 1.5;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -webkit-tap-highlight-color: transparent;
    -webkit-text-size-adjust: 100%;
}

/* COSMIC BACKGROUND */
.bg-cosmic { position: fixed; inset: 0; z-index: -2; background: var(--bg-deep); }
.nebula {
    position: fixed; inset: -20%; z-index: -1;
    background: radial-gradient(ellipse at 20% 20%, rgba(99,102,241,0.18) 0%, transparent 50%),
                radial-gradient(ellipse at 80% 80%, rgba(217,70,239,0.12) 0%, transparent 50%),
                radial-gradient(ellipse at 50% 50%, rgba(139,92,246,0.08) 0%, transparent 60%);
    animation: nebulaDrift 20s ease-in-out infinite alternate;
}
@keyframes nebulaDrift { from { transform: translate(-2%,-2%) scale(1); } to { transform: translate(2%,2%) scale(1.08); } }
.stars {
    position: fixed; inset: 0; z-index: -1;
    background-image: radial-gradient(2px 2px at 20px 30px, rgba(255,255,255,0.3), transparent),
                      radial-gradient(2px 2px at 40px 70px, rgba(255,255,255,0.2), transparent),
                      radial-gradient(1px 1px at 90px 40px, rgba(255,255,255,0.3), transparent),
                      radial-gradient(2px 2px at 160px 120px, rgba(255,255,255,0.2), transparent),
                      radial-gradient(1px 1px at 230px 80px, rgba(255,255,255,0.15), transparent);
    background-size: 250px 250px;
    opacity: 0.6;
}

/* OFFLINE BAR */
#offline-bar {
    position: fixed; top: 0; left: 0; right: 0; z-index: 999;
    background: rgba(245,158,11,0.15); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(245,158,11,0.3);
    color: #fbbf24; text-align: center; padding: 8px; font-size: 0.85rem; font-weight: 600;
}

/* HEADER */
header {
    display: flex; align-items: center; gap: 20px;
    padding: 14px 28px; padding-left: calc(28px + env(safe-area-inset-left)); padding-right: calc(28px + env(safe-area-inset-right));
    background: rgba(3,3,5,0.75); -webkit-backdrop-filter: blur(28px) saturate(150%); backdrop-filter: blur(28px) saturate(150%);
    border-bottom: 1px solid var(--glass-border);
    position: -webkit-sticky; position: sticky; top: 0; z-index: 100;
}
.logo { display: flex; align-items: center; gap: 12px; cursor: pointer; }
.logo-icon {
    width: 46px;
    height: 46px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 0 14px rgba(99,102,241,0.35));
}
.logo-text { display: flex; flex-direction: column; line-height: 1.1; }
.logo-text span { font-size: 1.25rem; font-weight: 800; letter-spacing: -0.03em; background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.version-badge { font-size: 0.6rem; font-weight: 800; padding: 2px 8px; border-radius: 999px; background: var(--accent-grad); color: #fff; width: fit-content; margin-top: 2px; }
nav { display: flex; gap: 6px; flex: 1; justify-content: center; }
.nav-link {
    padding: 10px 20px; border-radius: 999px; color: var(--text-muted); cursor: pointer;
    font-weight: 500; font-size: 0.9rem; transition: all var(--t-base);
    background: transparent; border: 1px solid transparent; font-family: inherit;
}
.nav-link:hover { background: rgba(255,255,255,0.06); color: #fff; }
.nav-link.active { background: rgba(99,102,241,0.15); color: #fff; border-color: rgba(99,102,241,0.35); box-shadow: inset 0 1px 0 rgba(255,255,255,0.1), 0 0 20px rgba(99,102,241,0.15); }

.header-actions { display: flex; align-items: center; gap: 10px; }
.lang-toggle {
    display: flex; align-items: center; gap: 6px; padding: 7px 12px;
    border-radius: 999px; background: rgba(255,255,255,0.05); border: 1px solid var(--glass-border);
    color: var(--text-muted); cursor: pointer; font-size: 0.82rem; font-weight: 600;
    transition: all var(--t-fast); font-family: inherit;
}
.lang-toggle:hover { background: rgba(255,255,255,0.1); color: #fff; border-color: var(--glass-border-strong); }
.cart-toggle {
    position: relative; padding: 8px 14px; border-radius: 999px;
    background: rgba(255,255,255,0.05); border: 1px solid var(--glass-border);
    color: #fff; cursor: pointer; font-size: 1.1rem; transition: all var(--t-fast);
}
.cart-toggle:hover { background: rgba(99,102,241,0.2); border-color: rgba(99,102,241,0.4); transform: translateY(-1px); }
.cart-badge {
    position: absolute; top: -4px; right: -4px;
    background: var(--accent-grad); color: #fff; font-size: 0.65rem; font-weight: 800;
    width: 18px; height: 18px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
}

/* CART PANEL */
.cart-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.6); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); z-index: 299; opacity: 0; pointer-events: none; transition: opacity 0.3s; }
.cart-overlay.open { opacity: 1; pointer-events: auto; }
.cart-panel {
    position: fixed; top: 0; right: 0; width: 420px; max-width: 100%; height: 100%;
    background: linear-gradient(180deg, rgba(10,10,18,0.98), rgba(6,6,12,0.98));
    border-left: 1px solid var(--glass-border); z-index: 300;
    transform: translateX(100%); transition: transform 0.4s cubic-bezier(.4,0,.2,1);
    display: flex; flex-direction: column;
}
.cart-panel.open { transform: translateX(0); }
.cart-header { display: flex; align-items: center; justify-content: space-between; padding: 24px; border-bottom: 1px solid var(--glass-border); }
.cart-header h3 { font-size: 1.15rem; font-weight: 700; }
.cart-close { width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,0.07); border: 1px solid var(--glass-border); color: #fff; cursor: pointer; font-size: 16px; display: flex; align-items: center; justify-content: center; transition: all var(--t-fast); }
.cart-close:hover { background: rgba(255,255,255,0.15); transform: rotate(90deg); }
.cart-body { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 16px; }
.cart-empty { text-align: center; padding: 60px 20px; color: var(--text-muted); font-size: 0.95rem; }
.cart-item {
    display: flex; align-items: center; gap: 12px; padding: 14px;
    background: var(--glass-bg); border: 1px solid var(--glass-border);
    border-radius: var(--radius-md); margin-bottom: 10px; transition: all var(--t-fast);
}
.cart-item:hover { border-color: var(--glass-border-strong); transform: translateX(4px); }
.cart-item-info { flex: 1; min-width: 0; }
.cart-item-info b { display: block; font-size: 0.92rem; margin-bottom: 2px; }
.cart-item-info small { color: var(--text-muted); font-size: 0.78rem; }
.cart-item-price { font-weight: 700; background: var(--accent-grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent; font-size: 0.95rem; white-space: nowrap; }
.cart-item button {
    width: 26px; height: 26px; border-radius: 50%; background: rgba(239,68,68,0.15);
    border: 1px solid rgba(239,68,68,0.3); color: #fca5a5; cursor: pointer;
    display: flex; align-items: center; justify-content: center; font-size: 12px; flex-shrink: 0;
    transition: all var(--t-fast);
}
.cart-item button:hover { background: rgba(239,68,68,0.3); color: #fff; }
.cart-footer { padding: 20px 24px; border-top: 1px solid var(--glass-border); background: rgba(0,0,0,0.3); }
.cart-total { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; font-size: 1.1rem; }
.cart-total b { font-size: 1.4rem; background: var(--accent-grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }

/* AUTH MENU */
.auth-menu { display: flex; align-items: center; }
.auth-guest { display: flex; gap: 8px; align-items: center; }
.auth-user { position: relative; }
.profile-chip { display: flex; align-items: center; gap: 10px; padding: 5px 14px 5px 5px; background: rgba(255,255,255,0.05); border: 1px solid var(--glass-border); border-radius: 999px; cursor: pointer; color: #fff; font-family: inherit; font-size: 0.9rem; font-weight: 500; transition: all var(--t-base); }
.profile-chip:hover { background: rgba(255,255,255,0.1); border-color: var(--glass-border-strong); }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--accent-grad); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 0.82rem; font-weight: 700; overflow: hidden; flex-shrink: 0; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar-lg { width: 72px; height: 72px; font-size: 1.5rem; }
.chev { font-size: 0.7rem; color: var(--text-muted); transition: transform var(--t-base); }
.profile-dropdown { position: absolute; top: calc(100% + 10px); right: 0; min-width: 220px; background: var(--glass-bg-strong); -webkit-backdrop-filter: blur(24px); backdrop-filter: blur(24px); border: 1px solid var(--glass-border-strong); border-radius: var(--radius-md); padding: 8px; box-shadow: var(--shadow-lg); opacity: 0; pointer-events: none; transform: translateY(-8px) scale(0.96); transition: all var(--t-base); z-index: 200; }
.profile-dropdown.show { opacity: 1; pointer-events: auto; transform: translateY(0) scale(1); }
.profile-dropdown button { display: block; width: 100%; text-align: left; padding: 10px 14px; background: transparent; border: none; color: var(--text-main); cursor: pointer; font-family: inherit; font-size: 0.92rem; border-radius: var(--radius-sm); transition: background var(--t-fast); }
.profile-dropdown button:hover { background: rgba(255,255,255,0.08); }
.profile-dropdown button.danger { color: #f87171; }
.profile-dropdown button.danger:hover { background: rgba(239,68,68,0.12); }
.profile-dropdown hr { border: none; border-top: 1px solid var(--glass-border); margin: 6px 0; }
.mobile-toggle { display: none; background: transparent; border: 1px solid var(--glass-border); color: #fff; border-radius: var(--radius-sm); padding: 8px 12px; font-size: 1.2rem; cursor: pointer; }

/* VIEWS */
.app-view { display: none; padding: 36px 28px; max-width: 1400px; margin: 0 auto; animation: fadeUp 0.4s cubic-bezier(0.4,0,0.2,1); }
.app-view.active { display: block; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

/* HERO */
.hero { text-align: center; padding: 100px 0 50px; max-width: 1000px; margin: 0 auto; position: relative; }
.hero-logo {
    width: clamp(112px, 16vw, 160px);
    height: clamp(112px, 16vw, 160px);
    object-fit: contain;
    display: block;
    margin: 0 auto 20px;
    filter: drop-shadow(0 24px 54px rgba(99,102,241,0.3));
}
.hero-badge { display: inline-flex; padding: 8px 20px; border-radius: 999px; background: rgba(99,102,241,0.1); border: 1px solid rgba(99,102,241,0.25); font-size: 0.82rem; color: #c7d2fe; font-weight: 500; margin-bottom: 32px; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.hero h1 { font-size: clamp(3rem, 9vw, 6rem); font-weight: 900; line-height: 1.05; letter-spacing: -0.04em; font-family: 'Space Grotesk', Inter, sans-serif; }
.gradient-text { background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; animation: shimmer 6s linear infinite; background-size: 200% 100%; }
@keyframes shimmer { 0% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } 100% { background-position: 0% 50%; } }
.hero p { color: var(--text-muted); font-size: clamp(1.1rem, 2.5vw, 1.35rem); margin: 28px 0 44px; line-height: 1.6; max-width: 600px; margin-left: auto; margin-right: auto; }
.hero-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.hero-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 80px; max-width: 720px; margin-left: auto; margin-right: auto; }
.hero-stats .stat { padding: 24px; background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: var(--radius-lg); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); transition: all var(--t-base); }
.hero-stats .stat:hover { transform: translateY(-4px); border-color: rgba(99,102,241,0.3); box-shadow: var(--shadow-glow); }
.hero-stats b { display: block; font-size: 1.7rem; font-weight: 800; margin-bottom: 6px; }
.hero-stats span { font-size: 0.85rem; color: var(--text-muted); }

/* FEATURE GRID */
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; margin-top: 60px; }
.feature-card {
    padding: 32px; background: linear-gradient(145deg, rgba(255,255,255,0.04), rgba(255,255,255,0.01));
    -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); border: 1px solid var(--glass-border); border-radius: var(--radius-xl);
    transition: all var(--t-slow); position: relative; overflow: hidden; transform-style: preserve-3d;
}
.feature-card:hover { border-color: rgba(99,102,241,0.35); transform: translateY(-6px) scale(1.01); box-shadow: var(--shadow-md), var(--shadow-glow); }
.feature-card::before {
    content: ''; position: absolute; inset: 0;
    background: radial-gradient(600px circle at var(--mouse-x,50%) var(--mouse-y,50%), rgba(99,102,241,0.1), transparent 40%);
    opacity: 0; transition: opacity 0.3s; pointer-events: none;
}
.feature-card:hover::before { opacity: 1; }
.feature-icon { font-size: 2.4rem; margin-bottom: 16px; display: inline-block; padding: 12px; background: rgba(99,102,241,0.1); border-radius: var(--radius-md); }
.feature-card h3 { font-size: 1.25rem; margin-bottom: 10px; font-weight: 700; }
.feature-card p { color: var(--text-muted); font-size: 0.95rem; line-height: 1.6; }

/* BUTTONS */
.btn {
    -webkit-appearance: none; appearance: none; padding: 12px 24px; border-radius: 999px; font-weight: 600; border: 1px solid var(--glass-border);
    background: rgba(255,255,255,0.04); color: #fff; cursor: pointer; transition: all var(--t-base);
    -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); font-size: 0.92rem; display: inline-flex; align-items: center; justify-content: center;
    gap: 8px; font-family: inherit; white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); background: rgba(255,255,255,0.1); box-shadow: var(--shadow-sm); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--accent-grad); border-color: transparent; box-shadow: 0 8px 32px rgba(99,102,241,0.35); }
.btn-primary:hover { box-shadow: 0 12px 40px rgba(99,102,241,0.5); filter: brightness(1.1); }
.btn-outline { background: transparent; border-color: var(--glass-border-strong); }
.btn-ghost { background: transparent; border-color: transparent; color: var(--text-main); }
.btn-ghost:hover { background: rgba(255,255,255,0.06); }
.btn-sm { padding: 8px 16px; font-size: 0.85rem; }
.btn-lg { padding: 16px 36px; font-size: 1.05rem; }
.btn-block { width: 100%; padding: 16px; margin-top: 12px; }
.btn-google { -webkit-appearance: none; appearance: none; display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; padding: 14px 16px; background: #fff; color: #1f1f1f; border: none; border-radius: 999px; font-weight: 600; cursor: pointer; font-family: inherit; font-size: 0.95rem; transition: all var(--t-base); }
.btn-google:hover { background: #f4f4f5; box-shadow: var(--shadow-sm); transform: translateY(-1px); }

/* CATALOG */
.catalog-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 28px; flex-wrap: wrap; gap: 16px; }
.catalog-header h2 { font-size: clamp(1.8rem, 4vw, 2.4rem); font-weight: 800; letter-spacing: -0.02em; }
.search-box { position: relative; width: 320px; max-width: 100%; }
.search-box input { background: rgba(0,0,0,0.4); border: 1px solid var(--glass-border); color: #fff; padding: 12px 18px; border-radius: var(--radius-md); width: 100%; outline: none; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); transition: all var(--t-base); font-family: inherit; font-size: 16px; }
.search-box input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(99,102,241,0.15); }
.filter-container { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; }
.filter-chip { padding: 8px 18px; border-radius: 999px; background: var(--glass-bg); border: 1px solid var(--glass-border); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); color: var(--text-muted); font-weight: 500; font-size: 0.88rem; cursor: pointer; transition: all var(--t-base); user-select: none; }
.filter-chip:hover { color: #fff; border-color: var(--glass-border-strong); }
.filter-chip.active { background: var(--accent-grad); color: #fff; border-color: transparent; box-shadow: 0 4px 20px rgba(99,102,241,0.35); }
.grid-catalog { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 24px; }
.product-card {
    background: var(--glass-bg); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); border: 1px solid var(--glass-border);
    border-radius: var(--radius-xl); overflow: hidden; transition: all var(--t-slow); cursor: pointer; position: relative;
}
.product-card:hover { border-color: rgba(99,102,241,0.35); transform: translateY(-6px); box-shadow: var(--shadow-md), var(--shadow-glow); }
.img-carousel { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; height: 220px; cursor: grab; scrollbar-width: none; background: #0a0a14; }
.img-carousel::-webkit-scrollbar { display: none; }
.carousel-slide { flex: 0 0 100%; scroll-snap-align: start; background-size: cover; background-position: center; transition: transform var(--t-slow); }
.product-card:hover .carousel-slide { transform: scale(1.05); }
.card-content { padding: 22px; }
.card-content h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 6px; line-height: 1.3; }
.card-footer { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; }
.price { font-size: 1.3rem; font-weight: 800; background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.muted { color: var(--text-muted); font-size: 0.88rem; }
.price-group { display: flex; align-items: baseline; gap: 8px; }
.price-old { font-size: 0.88rem; color: var(--text-dim); text-decoration: line-through; }

/* ORDER & CUSTOM */
.order-container, .custom-container { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; max-width: 1400px; margin: 0 auto; }
.order-viewer { background: var(--glass-bg); -webkit-backdrop-filter: blur(22px); backdrop-filter: blur(22px); border: 1px solid var(--glass-border); border-radius: var(--radius-xl); padding: 8px; min-height: 500px; height: 60vh; position: relative; overflow: hidden; width: 100%; }
#stl-canvas { display: block; width: 100% !important; height: 100% !important; border-radius: var(--radius-lg); outline: none; }
.order-form, .custom-upload, .custom-form { background: var(--glass-bg); -webkit-backdrop-filter: blur(22px); backdrop-filter: blur(22px); border: 1px solid var(--glass-border); border-radius: var(--radius-xl); padding: 32px; }
.order-form h2 { font-size: 1.9rem; margin-bottom: 8px; letter-spacing: -0.02em; }
.order-form p { color: var(--text-muted); margin-bottom: 24px; }
.custom-form { opacity: 0.5; pointer-events: none; transition: opacity var(--t-base); }
.custom-form.active { opacity: 1; pointer-events: all; }
.dropzone { border: 2px dashed var(--glass-border-strong); border-radius: var(--radius-xl); padding: 48px 24px; text-align: center; cursor: pointer; background: rgba(0,0,0,0.25); margin: 20px 0; transition: all var(--t-base); }
.dropzone:hover { border-color: var(--accent); background: rgba(99,102,241,0.08); transform: translateY(-2px); }
.dropzone-icon { font-size: 3.2rem; margin-bottom: 10px; }
.dropzone h3 { font-size: 1.15rem; margin-bottom: 4px; }

/* FORM ELEMENTS */
label { font-size: 0.78rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.07em; margin-bottom: 8px; display: block; font-weight: 600; }
input, select, textarea { background: rgba(0,0,0,0.4); border: 1px solid var(--glass-border); color: #fff; padding: 13px 16px; border-radius: var(--radius-md); width: 100%; outline: none; font-size: 16px; -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); margin-bottom: 18px; transition: all var(--t-base); font-family: inherit; }
input:focus, select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(99,102,241,0.12); }
input[type="range"] { padding: 0; margin-bottom: 8px; background: transparent; border: none; -webkit-appearance: none; height: 6px; }
input[type="range"]::-webkit-slider-runnable-track { height: 6px; background: rgba(255,255,255,0.08); border-radius: 4px; }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; background: var(--accent-grad); border-radius: 50%; margin-top: -8px; cursor: pointer; box-shadow: 0 0 0 5px rgba(99,102,241,0.2); }
textarea { resize: vertical; min-height: 80px; }
select { appearance: none; background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'><path fill='%2394a3b8' d='M6 8L2 4h8z'/></svg>"); background-repeat: no-repeat; background-position: right 16px center; padding-right: 40px; }
.form-hint { color: var(--text-muted); font-size: 0.82rem; line-height: 1.5; margin: 8px 0 20px; padding: 12px 14px; background: rgba(99,102,241,0.08); border: 1px solid rgba(99,102,241,0.18); border-radius: var(--radius-sm); }
.custom-layer-label { margin-top: 26px; }
.form-icon { display: inline-flex; align-items: center; justify-content: center; width: 18px; height: 18px; border-radius: 6px; background: rgba(99,102,241,0.18); color: #c7d2fe; font-size: 0.78rem; font-weight: 800; letter-spacing: 0; vertical-align: -2px; }

.color-selector { display: grid; grid-template-columns: repeat(auto-fill, minmax(40px, 1fr)); gap: 10px; margin-bottom: 20px; padding: 16px; background: rgba(0,0,0,0.3); border: 1px solid var(--glass-border); border-radius: var(--radius-md); max-height: 200px; overflow-y: auto; -webkit-overflow-scrolling: touch; scrollbar-width: thin; scrollbar-color: rgba(99,102,241,.3) transparent; }
.color-selector::-webkit-scrollbar { width: 6px; }
.color-selector::-webkit-scrollbar-thumb { background: rgba(99,102,241,.3); border-radius: 3px; }
.color-bubble { width: 36px; height: 36px; border-radius: 50%; cursor: pointer; border: 2px solid transparent; transition: all var(--t-fast); box-shadow: inset -2px -3px 5px rgba(0,0,0,.3), inset 1px 2px 3px rgba(255,255,255,.08), 0 2px 6px rgba(0,0,0,.4); position: relative; }
.color-bubble:hover { transform: scale(1.12); }
.color-bubble.selected { border-color: var(--accent); transform: scale(1.15); box-shadow: inset -2px -3px 5px rgba(0,0,0,.3), inset 1px 2px 3px rgba(255,255,255,.08), 0 0 0 3px rgba(99,102,241,.35), 0 4px 16px rgba(99,102,241,.3); }
.color-bubble.selected::after { content: '✓'; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 800; font-size: 1rem; text-shadow: 0 1px 4px rgba(0,0,0,.6); pointer-events: none; }

.price-display { font-size: 2.8rem; font-weight: 800; margin: 24px 0 10px; background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; letter-spacing: -0.02em; }

/* AUTH MODAL */
.auth-modal-content { background: var(--glass-bg-strong); -webkit-backdrop-filter: blur(32px) saturate(140%); backdrop-filter: blur(32px) saturate(140%); border: 1px solid var(--glass-border-strong); border-radius: var(--radius-xl); padding: 40px 36px 32px; max-width: 460px; width: 100%; max-height: 92vh; overflow-y: auto; -webkit-overflow-scrolling: touch; position: relative; box-shadow: var(--shadow-lg); animation: modalPop 0.35s cubic-bezier(0.34, 1.56, 0.64, 1); }
@keyframes modalPop { from { opacity: 0; transform: scale(0.92) translateY(10px); } to { opacity: 1; transform: scale(1) translateY(0); } }
.auth-modal-content .modal-close { position: absolute; top: 16px; right: 16px; width: 36px; height: 36px; background: rgba(255,255,255,0.06); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; font-size: 22px; border: 1px solid var(--glass-border); transition: all var(--t-base); }
.auth-modal-content .modal-close:hover { background: rgba(255,255,255,0.14); transform: rotate(90deg); }
.auth-tabs { display: flex; background: rgba(0,0,0,0.35); border: 1px solid var(--glass-border); border-radius: 999px; padding: 4px; margin-bottom: 28px; }
.auth-tab { flex: 1; padding: 10px 14px; background: transparent; border: none; color: var(--text-muted); border-radius: 999px; font-weight: 600; font-size: 0.92rem; cursor: pointer; font-family: inherit; transition: all var(--t-base); }
.auth-tab.active { background: var(--accent-grad); color: #fff; box-shadow: 0 4px 20px rgba(99,102,241,0.35); }
.auth-panel { display: none; }
.auth-panel.active { display: block; animation: fadeUp 0.25s ease; }
.auth-panel h2 { font-size: 1.6rem; margin-bottom: 4px; font-weight: 800; letter-spacing: -0.02em; }
.auth-panel p.muted { margin-bottom: 22px; }
.auth-divider { display: flex; align-items: center; gap: 12px; margin: 20px 0; color: var(--text-dim); font-size: 0.8rem; }
.auth-divider::before, .auth-divider::after { content: ""; flex: 1; height: 1px; background: var(--glass-border); }
.auth-switch { margin-top: 18px; text-align: center; color: var(--text-muted); font-size: 0.9rem; }
.auth-switch a { color: #c7d2fe; cursor: pointer; font-weight: 600; text-decoration: none; }
.auth-switch a:hover { text-decoration: underline; }

/* PROFILE */
.profile-wrap { max-width: 640px; margin: 0 auto; display: flex; flex-direction: column; gap: 24px; }
.profile-header { display: flex; align-items: center; gap: 20px; padding: 28px; background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: var(--radius-xl); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
.profile-header h2 { font-size: 1.6rem; font-weight: 800; letter-spacing: -0.02em; }
.card { background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: var(--radius-xl); padding: 28px; -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
.card h3 { font-size: 1.15rem; margin-bottom: 18px; font-weight: 700; }

/* ORDERS */
.orders-list { display: flex; flex-direction: column; gap: 14px; }
.order-item { display: flex; align-items: center; gap: 16px; padding: 20px; background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: var(--radius-lg); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); transition: all var(--t-base); }
.order-item:hover { border-color: var(--glass-border-strong); transform: translateX(4px); }
.order-swatch { width: 52px; height: 52px; border-radius: var(--radius-md); box-shadow: inset 0 0 0 1px rgba(255,255,255,0.15); flex-shrink: 0; }
.order-main { flex: 1; min-width: 0; }
.order-title { font-weight: 700; margin-bottom: 4px; }
.order-meta { display: flex; gap: 12px; flex-wrap: wrap; color: var(--text-muted); font-size: 0.82rem; }
.order-note { margin-top: 8px; color: var(--text-muted); font-size: 0.88rem; line-height: 1.4; }
.order-status { padding: 6px 14px; border-radius: 999px; font-size: 0.78rem; font-weight: 600; white-space: nowrap; border: 1px solid transparent; }
.badge-beklemede { background: rgba(245,158,11,0.15); color: #fbbf24; border-color: rgba(245,158,11,0.3); }
.badge-onaylandi { background: rgba(6,182,212,0.15); color: #22d3ee; border-color: rgba(6,182,212,0.3); }
.badge-slicing { background: rgba(139,92,246,0.15); color: #a78bfa; border-color: rgba(139,92,246,0.3); }
.badge-uretimde { background: rgba(99,102,241,0.18); color: #a5b4fc; border-color: rgba(99,102,241,0.35); }
.badge-kalite_kontrol { background: rgba(236,72,153,0.15); color: #f472b6; border-color: rgba(236,72,153,0.3); }
.badge-kargoda { background: rgba(59,130,246,0.18); color: #93c5fd; border-color: rgba(59,130,246,0.35); }
.badge-teslim_edildi { background: rgba(16,185,129,0.18); color: #6ee7b7; border-color: rgba(16,185,129,0.35); }
.badge-iptal { background: rgba(239,68,68,0.15); color: #fca5a5; border-color: rgba(239,68,68,0.3); }
.empty-state { text-align: center; padding: 70px 20px; color: var(--text-muted); }
.empty-state .empty-icon { font-size: 4.5rem; margin-bottom: 18px; }
.empty-state h3 { color: var(--text-main); font-size: 1.3rem; margin-bottom: 8px; }
.empty-state p { margin-bottom: 24px; color: var(--text-muted); }

/* IMAGE MODAL */
.modal { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.92); -webkit-backdrop-filter: blur(24px); backdrop-filter: blur(24px); z-index: 1000; align-items: center; justify-content: center; padding: 20px; padding-bottom: calc(20px + env(safe-area-inset-bottom)); }
.modal.show { display: flex; }
.modal-content { position: relative; width: 100%; max-width: 1200px; height: 85vh; display: flex; align-items: center; }
.modal-close { position: absolute; top: -50px; right: 0; font-size: 32px; cursor: pointer; color: #fff; z-index: 10; background: rgba(255,255,255,0.1); width: 48px; height: 48px; border-radius: 50%; display: flex; align-items: center; justify-content: center; border: 1px solid var(--glass-border); transition: all var(--t-base); }
.modal-close:hover { background: rgba(255,255,255,0.2); transform: rotate(90deg); }
.modal-gallery { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; width: 100%; height: 100%; border-radius: var(--radius-xl); scrollbar-width: none; }
.modal-gallery::-webkit-scrollbar { display: none; }
.modal-slide { flex: 0 0 100%; scroll-snap-align: center; background-size: contain; background-repeat: no-repeat; background-position: center; }
.nav-arrow { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(255,255,255,0.1); border-radius: 50%; width: 50px; height: 50px; display: flex; align-items: center; justify-content: center; cursor: pointer; font-size: 28px; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); border: 1px solid var(--glass-border); color: #fff; transition: all var(--t-base); }
.nav-arrow:hover { background: rgba(255,255,255,0.22); }
.prev { left: 20px; } .next { right: 20px; }

/* LOADING & TOAST */
.loading-spinner { width: 44px; height: 44px; border: 3px solid rgba(255,255,255,0.08); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.9s linear infinite; margin: 36px auto; }
@keyframes spin { to { transform: rotate(360deg); } }
#toast-container { position: fixed; top: 20px; right: 20px; z-index: 9999; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.toast { background: var(--glass-bg-strong); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); border: 1px solid var(--glass-border-strong); border-left: 4px solid var(--success); padding: 14px 22px; border-radius: var(--radius-md); box-shadow: var(--shadow-lg); animation: slide 0.35s cubic-bezier(0.34, 1.56, 0.64, 1); font-weight: 500; font-size: 0.92rem; pointer-events: auto; max-width: 380px; }
.toast.error { border-left-color: var(--danger); }
@keyframes slide { from { opacity: 0; transform: translateX(40px); } to { opacity: 1; transform: translateX(0); } }

/* CAMPAIGN */
.campaign-badge { position: absolute; top: 14px; left: 14px; z-index: 5; background: linear-gradient(135deg, #ef4444, #f97316); color: #fff; font-size: 0.74rem; font-weight: 800; padding: 6px 14px; border-radius: 999px; letter-spacing: 0.04em; box-shadow: 0 4px 16px rgba(239,68,68,.5); animation: pulseBadge 2.5s ease-in-out infinite; pointer-events: none; }
@keyframes pulseBadge { 0%,100% { box-shadow: 0 4px 16px rgba(239,68,68,.5); } 50% { box-shadow: 0 4px 28px rgba(239,68,68,.8); } }
.has-campaign { border-color: rgba(239,68,68,.35); }
.has-campaign:hover { border-color: rgba(239,68,68,.6); }
.campaign-slider { margin-top: 70px; }
.campaign-slider-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; }
.campaign-slider-header h2 { font-size: 1.6rem; font-weight: 800; background: linear-gradient(135deg, #ef4444, #f97316); -webkit-background-clip: text; -webkit-text-fill-color: transparent; letter-spacing: -0.02em; }
.campaign-slider-nav { display: flex; gap: 8px; }
.campaign-slider-nav button { width: 40px; height: 40px; border-radius: 50%; background: var(--glass-bg); border: 1px solid var(--glass-border-strong); color: #fff; font-size: 22px; cursor: pointer; transition: all var(--t-base); font-family: inherit; }
.campaign-slider-nav button:hover { background: rgba(99,102,241,.25); border-color: rgba(99,102,241,.5); }
.campaign-slider-track { display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none; padding-bottom: 10px; }
.campaign-slider-track::-webkit-scrollbar { display: none; }
.campaign-item { flex: 0 0 280px; scroll-snap-align: start; background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: var(--radius-xl); overflow: hidden; cursor: pointer; transition: all var(--t-slow); }
.campaign-item:hover { transform: translateY(-6px); border-color: rgba(239,68,68,.5); box-shadow: 0 20px 48px rgba(239,68,68,.15); }
.campaign-item-img { height: 190px; background-size: cover; background-position: center; background-color: #0a0a14; position: relative; }
.campaign-badge-slider { position: absolute; top: 12px; left: 12px; background: linear-gradient(135deg, #ef4444, #f97316); color: #fff; font-weight: 800; font-size: .8rem; padding: 6px 14px; border-radius: 999px; box-shadow: 0 4px 16px rgba(239,68,68,.5); animation: pulseBadge 2s ease-in-out infinite; }
.campaign-item-body { padding: 16px; }
.campaign-item-title { font-weight: 700; font-size: 1rem; margin-bottom: 4px; }
.campaign-item-price { display: flex; align-items: baseline; gap: 10px; margin-top: 10px; }
.campaign-item-price .new-price { font-size: 1.3rem; font-weight: 800; background: linear-gradient(135deg, #ef4444, #f97316); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.campaign-item-price .old-price { text-decoration: line-through; color: var(--text-dim); font-size: .9rem; }

/* AR BADGE */
.btn-ar { background: rgba(99,102,241,.15) !important; border-color: rgba(99,102,241,.35) !important; color: #a5b4fc !important; box-shadow: 0 2px 10px rgba(99,102,241,.2); }
.btn-ar:hover { background: rgba(99,102,241,.3) !important; box-shadow: 0 4px 20px rgba(99,102,241,.35); transform: scale(1.08); }

/* INFO ICONS */
.info-icon { display: inline-block; width: 18px; height: 18px; line-height: 18px; text-align: center; background: rgba(99,102,241,.2); color: #a5b4fc; border-radius: 50%; font-size: 11px; font-weight: 700; cursor: help; margin-left: 6px; transition: all var(--t-fast); vertical-align: middle; }
.info-icon:hover { background: rgba(99,102,241,.4); color: #fff; transform: scale(1.15); }

/* PWA BANNER */
.pwa-banner { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: var(--glass-bg-strong); -webkit-backdrop-filter: blur(24px); backdrop-filter: blur(24px); border: 1px solid var(--glass-border-strong); border-radius: 999px; padding: 14px 28px; display: flex; align-items: center; gap: 16px; z-index: 500; box-shadow: var(--shadow-lg); animation: fadeUp 0.4s ease; font-size: 0.92rem; font-weight: 500; white-space: nowrap; }

/* SKELETON */
.skeleton { background: linear-gradient(90deg, rgba(255,255,255,0.03) 25%, rgba(255,255,255,0.08) 50%, rgba(255,255,255,0.03) 75%); background-size: 200% 100%; animation: skeleton 1.5s infinite; border-radius: 12px; }
@keyframes skeleton { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* RESPONSIVE */
@media (max-width: 900px) {
    header { padding: 12px 16px; flex-wrap: wrap; gap: 10px; }
    .logo-text span { font-size: 1.1rem; }
    nav { order: 3; width: 100%; display: none; flex-direction: column; gap: 4px; padding-top: 10px; }
    nav.mobile-open { display: flex; }
    .nav-link { width: 100%; text-align: left; padding: 12px 16px; }
    .auth-menu { margin-left: auto; }
    .mobile-toggle { display: inline-flex; }
    .app-view { padding: 24px 16px; }
    .hero { padding: 50px 0 30px; }
    .hero h1 { font-size: clamp(2.4rem, 9vw, 3.6rem); }
    .hero-stats { grid-template-columns: 1fr; gap: 12px; }
    .order-container, .custom-container { grid-template-columns: 1fr; }
    .order-viewer { height: 360px; min-height: 360px; }
    .order-item { flex-wrap: wrap; }
    .order-status { order: -1; margin-left: auto; }
    .auth-modal-content { padding: 32px 24px 24px; max-width: calc(100% - 20px); }
    .hero-buttons { flex-direction: column; width: 100%; max-width: 340px; margin: 0 auto; }
    .hero-buttons .btn { width: 100%; }
    .cart-panel { width: 100%; }
}
@media (max-width: 480px) {
    .catalog-header { flex-direction: column; align-items: stretch; }
    .search-box { width: 100%; }
    .grid-catalog { grid-template-columns: 1fr; }
    .profile-header { flex-direction: column; text-align: center; }
    .version-badge { display: none; }
    .header-actions .btn-ghost { display: none; }
}

/* =========================================================
   SAFARI iOS UYUMLULUK
   ========================================================= */
button { -webkit-appearance: none; appearance: none; }
input, select, textarea { -webkit-appearance: none; appearance: none; }
input[type="range"] { -webkit-appearance: none; }
input::-webkit-search-cancel-button { -webkit-appearance: none; }
* { -webkit-tap-highlight-color: transparent; }
a, button { -webkit-touch-callout: none; }
.cart-panel, .auth-modal-content, .cart-body, .color-selector { -webkit-overflow-scrolling: touch; }

/* iOS Safari: position:fixed inside scrolling parent jank fix */
@supports (-webkit-touch-callout: none) {
    body { min-height: -webkit-fill-available; }
    .hero { min-height: auto; }
}

/* Safari: backdrop-filter olmayan eski sürümler için fallback */
@supports not (backdrop-filter: blur(1px)) {
    @supports not (-webkit-backdrop-filter: blur(1px)) {
        header { background: rgba(3,3,5,0.95); }
        .auth-modal-content { background: rgba(12,12,22,0.98); }
        .modal { background: rgba(0,0,0,0.95); }
        .profile-dropdown { background: rgba(12,12,22,0.98); }
        .toast { background: rgba(12,12,22,0.98); }
    }
}
/* Safari iOS fix end */
