/* 科技感自動發卡系統樣式 */

@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;500;700;900&family=Rajdhani:wght@300;400;500;600;700&display=swap');

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

:root {
    --primary: #00f0ff;
    --secondary: #ff006e;
    --dark: #0a0e27;
    --darker: #050816;
    --light: #ffffff;
    --gray: #8892b0;
    --success: #00ff88;
    --danger: #ff0055;
    --warning: #ffaa00;
}

body {
    font-family: 'Rajdhani', sans-serif;
    background: var(--darker);
    color: var(--light);
    overflow-x: hidden;
    line-height: 1.6;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ==================== 科技背景 ==================== */
.tech-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: 
        radial-gradient(ellipse at top, rgba(0, 240, 255, 0.1), transparent),
        radial-gradient(ellipse at bottom, rgba(255, 0, 110, 0.1), transparent),
        var(--darker);
}

.grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(0, 240, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 240, 255, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
    0% { transform: translateY(0); }
    100% { transform: translateY(50px); }
}

.particles {
    position: absolute;
    width: 100%;
    height: 100%;
}

/* ==================== 導航欄 ==================== */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(10, 14, 39, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 240, 255, 0.2);
    z-index: 1000;
    padding: 1rem 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 10px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.nav-brand i {
    font-size: 1.8rem;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.nav-menu {
    display: flex;
    gap: 2rem;
}

.nav-menu a {
    color: var(--gray);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    transition: all 0.3s;
    position: relative;
    padding: 5px 0;
}

.nav-menu a:hover {
    color: var(--primary);
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s;
}

.nav-menu a:hover::after {
    width: 100%;
}

/* ==================== Hero 區塊 ==================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 100px 0;
    position: relative;
}

.hero-content {
    text-align: center;
    z-index: 2;
}

.glitch {
    font-family: 'Orbitron', sans-serif;
    font-size: 4.5rem;
    font-weight: 900;
    text-transform: uppercase;
    position: relative;
    color: var(--primary);
    letter-spacing: 5px;
    animation: glitch 3s infinite;
    text-shadow: 
        0 0 10px rgba(0, 240, 255, 0.5),
        0 0 20px rgba(0, 240, 255, 0.3);
}

@keyframes glitch {
    0%, 100% { text-shadow: 0 0 10px rgba(0, 240, 255, 0.5); }
    25% { text-shadow: -2px 0 10px rgba(255, 0, 110, 0.5); }
    50% { text-shadow: 2px 0 10px rgba(0, 240, 255, 0.5); }
    75% { text-shadow: -2px 0 10px rgba(0, 240, 255, 0.5); }
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--gray);
    margin: 20px 0 40px;
    font-weight: 300;
}

.typed-text {
    border-right: 2px solid var(--primary);
    animation: blink 0.7s infinite;
}

@keyframes blink {
    50% { border-color: transparent; }
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 4rem;
    margin: 50px 0;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

.stat-item i {
    font-size: 3rem;
    color: var(--primary);
}

.stat-number {
    font-family: 'Orbitron', sans-serif;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
}

.stat-label {
    color: var(--gray);
    font-size: 0.9rem;
}

.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 18px 40px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: var(--light);
    text-decoration: none;
    border-radius: 50px;
    font-size: 1.2rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s;
}

.cta-button:hover::before {
    left: 100%;
}

.cta-button:hover {
    transform: translateY(-3px);
}

/* ==================== 搜尋區塊 ==================== */
.search-section {
    padding: 80px 0 40px;
    margin-top: 60px;
}

.search-bar {
    max-width: 800px;
    margin: 0 auto 40px;
}

.search-input-wrapper {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(0, 240, 255, 0.3);
    border-radius: 50px;
    padding: 5px;
    backdrop-filter: blur(10px);
}

.search-input-wrapper i {
    margin: 0 20px;
    color: var(--primary);
    font-size: 1.3rem;
}

.search-input-wrapper input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: var(--light);
    font-size: 1.1rem;
    padding: 10px;
}

.search-input-wrapper input::placeholder {
    color: var(--gray);
}

.search-btn {
    padding: 12px 30px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: none;
    border-radius: 50px;
    color: var(--light);
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s;
}

.search-btn:hover {
    transform: scale(1.05);
}

/* ==================== 分類篩選 ==================== */
.category-filter {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.category-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 25px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(0, 240, 255, 0.2);
    border-radius: 50px;
    color: var(--gray);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
}

.category-item:hover,
.category-item.active {
    background: rgba(0, 240, 255, 0.1);
    border-color: var(--primary);
    color: var(--primary);
}

.category-item i {
    font-size: 1.2rem;
}

/* ==================== 商品卡片 ==================== */
.products-section {
    padding: 60px 0 100px;
}

.search-result-info {
    text-align: center;
    margin-bottom: 40px;
    color: var(--gray);
}

.search-result-info strong {
    color: var(--primary);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
}

.product-card-tech {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(0, 240, 255, 0.2);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.3s;
    position: relative;
}

.product-card-tech::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 240, 255, 0.1), transparent);
    transition: left 0.5s;
}

.product-card-tech:hover::before {
    left: 100%;
}

.product-card-tech:hover {
    transform: translateY(-10px);
    border-color: var(--primary);
    box-shadow: 0 10px 40px rgba(0, 240, 255, 0.3);
}

.product-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-image.placeholder {
    background: linear-gradient(135deg, rgba(0, 240, 255, 0.1), rgba(255, 0, 110, 0.1));
}

.product-image.placeholder i {
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.2);
}

.product-badge-tech {
    position: absolute;
    top: 15px;
    right: 15px;
    z-index: 2;
}

.badge-available-tech,
.badge-soldout-tech {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
}

.badge-available-tech {
    background: rgba(0, 255, 136, 0.2);
    border: 1px solid var(--success);
    color: var(--success);
}

.badge-soldout-tech {
    background: rgba(255, 0, 85, 0.2);
    border: 1px solid var(--danger);
    color: var(--danger);
}

.product-category {
    position: absolute;
    top: 15px;
    left: 15px;
    padding: 6px 12px;
    background: rgba(0, 240, 255, 0.2);
    border: 1px solid var(--primary);
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--primary);
}

.product-info {
    padding: 25px;
}

.product-info h3 {
    font-size: 1.4rem;
    margin-bottom: 10px;
    color: var(--light);
}

.product-info p {
    color: var(--gray);
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.product-footer-tech {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-top: 15px;
    border-top: 1px solid rgba(0, 240, 255, 0.2);
}

.price-tech {
    font-family: 'Orbitron', sans-serif;
}

.price-tech .currency {
    color: var(--gray);
    font-size: 1rem;
}

.price-tech .amount {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
}

.stock-tech {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--gray);
}

.buy-btn-tech {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: none;
    border-radius: 10px;
    color: var(--light);
    font-weight: 600;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
}

.buy-btn-tech:hover {
    transform: scale(1.05);
}

.buy-btn-tech.disabled {
    background: rgba(255, 255, 255, 0.1);
    cursor: not-allowed;
    opacity: 0.5;
}

/* ==================== 空狀態 ==================== */
.empty-state-tech {
    text-align: center;
    padding: 100px 20px;
}

.empty-state-tech i {
    font-size: 5rem;
    color: var(--gray);
    opacity: 0.5;
    margin-bottom: 20px;
}

.empty-state-tech h3 {
    font-size: 2rem;
    color: var(--light);
    margin-bottom: 10px;
}

.empty-state-tech p {
    color: var(--gray);
    margin-bottom: 30px;
}

.btn-tech {
    display: inline-block;
    padding: 12px 30px;
    background: var(--primary);
    color: var(--dark);
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
}

/* ==================== 特色區塊 ==================== */
.features-tech {
    padding: 100px 0;
    background: rgba(0, 0, 0, 0.3);
}

.section-title-tech {
    font-family: 'Orbitron', sans-serif;
    text-align: center;
    font-size: 3rem;
    margin-bottom: 60px;
    color: var(--primary);
    text-transform: uppercase;
}

.features-grid-tech {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.feature-card-tech {
    text-align: center;
    padding: 40px 30px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(0, 240, 255, 0.2);
    border-radius: 20px;
    transition: all 0.3s;
}

.feature-card-tech:hover {
    transform: translateY(-10px);
    border-color: var(--primary);
    background: rgba(0, 240, 255, 0.05);
}

.feature-icon-tech {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.feature-icon-tech i {
    font-size: 2.5rem;
    color: var(--light);
}

.feature-card-tech h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.feature-card-tech p {
    color: var(--gray);
}

/* ==================== 使用說明 ==================== */
.howto-section-tech {
    padding: 100px 0;
}

.steps-tech {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.step-tech {
    text-align: center;
    flex: 1;
    position: relative;
}

.step-number-tech {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Orbitron', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    margin: 0 auto 20px;
}

.step-tech i {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 15px;
}

.step-tech h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.step-tech p {
    color: var(--gray);
}

.step-arrow-tech {
    color: var(--primary);
    font-size: 2rem;
}

/* ==================== 頁腳 ==================== */
.footer-tech {
    background: rgba(0, 0, 0, 0.5);
    padding: 60px 0 30px;
    border-top: 1px solid rgba(0, 240, 255, 0.2);
}

.footer-content-tech {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.footer-content-tech h3 {
    font-family: 'Orbitron', sans-serif;
    color: var(--primary);
    font-size: 1.5rem;
}

.footer-links-tech {
    display: flex;
    gap: 30px;
}

.footer-links-tech a {
    color: var(--gray);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links-tech a:hover {
    color: var(--primary);
}

.footer-bottom-tech {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(0, 240, 255, 0.1);
    color: var(--gray);
}

/* ==================== 響應式設計 ==================== */
@media (max-width: 768px) {
    .glitch {
        font-size: 2.5rem;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 2rem;
    }
    
    .nav-menu {
        flex-direction: column;
        gap: 1rem;
    }
    
    .category-filter {
        gap: 10px;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }

    .product-badge-tech {
        flex-wrap: wrap;
        gap: 4px;
    }

    .product-badge-tech span {
        font-size: 0.72rem !important;
        padding: 2px 8px !important;
    }

    .buy-btn-tech {
        padding: 12px 16px;
        font-size: 0.95rem;
    }

    .product-info h3 {
        font-size: 1rem;
    }

    .price-tech .amount {
        font-size: 1.4rem;
    }

    .navbar .container {
        flex-wrap: wrap;
        gap: 8px;
    }

    .nav-menu {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 8px;
        justify-content: center;
    }

    .nav-menu a {
        font-size: 0.85rem;
        padding: 6px 10px;
    }
    
    .steps-tech {
        flex-direction: column;
        gap: 30px;
    }
    
    .step-arrow-tech {
        transform: rotate(90deg);
    }
    
    .footer-content-tech {
        flex-direction: column;
        gap: 30px;
        text-align: center;
    }
}
