﻿/*
 * ============================================================
 * Anyhave Jewelry — 品牌风格变量
 * 弹窗 + CAD 预约系统共用样式
 * ============================================================
 */

:root {
    /* Brand Colors */
    --anyhave-gold: #C8A96E;
    --anyhave-gold-dark: #A8894F;
    --anyhave-gold-light: #E8D5B0;
    --anyhave-white: #FDFBF7;
    --anyhave-cream: #F5F0E8;
    --anyhave-charcoal: #2C2C2C;
    --anyhave-text: #3D3D3D;
    --anyhave-text-light: #787878;
    --anyhave-accent: #1A1A1A;

    /* Functional */
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
    --shadow-md: 0 8px 32px rgba(0,0,0,0.10);
    --shadow-lg: 0 16px 48px rgba(0,0,0,0.14);
    --radius: 8px;
    --radius-lg: 12px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==================== Reset ==================== */
.anyhave-widget, .anyhave-widget * {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}
.anyhave-widget {
    font-family: 'Cormorant Garamond', 'Georgia', 'Times New Roman', serif;
    color: var(--anyhave-text);
    -webkit-font-smoothing: antialiased;
}

/* ==================== Popup Overlay ==================== */
.anyhave-popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    backdrop-filter: blur(4px);
    z-index: 99998;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* ==================== Popup Card ==================== */
.anyhave-popup {
    background: var(--anyhave-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    width: 90%;
    max-width: 520px;
    position: relative;
    overflow: hidden;
    animation: slideUp 0.4s ease;
}
@keyframes slideUp {
    from { transform: translateY(30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.anyhave-popup-close {
    position: absolute;
    top: 16px;
    right: 20px;
    background: none;
    border: none;
    font-size: 24px;
    color: var(--anyhave-text-light);
    cursor: pointer;
    z-index: 2;
    width: 36px; height: 36px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
}
.anyhave-popup-close:hover { background: var(--anyhave-cream); color: var(--anyhave-charcoal); }

.anyhave-popup-header {
    background: linear-gradient(135deg, var(--anyhave-charcoal), var(--anyhave-accent));
    padding: 32px 36px 28px;
    text-align: center;
}
.anyhave-popup-header .brand-name {
    font-size: 14px;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--anyhave-gold);
    margin-bottom: 8px;
}
.anyhave-popup-header h2 {
    font-size: 26px;
    color: white;
    font-weight: 400;
    line-height: 1.3;
}
.anyhave-popup-header p {
    color: rgba(255,255,255,0.7);
    font-size: 15px;
    margin-top: 8px;
}

.anyhave-popup-body {
    padding: 28px 36px 32px;
}

/* ==================== Form Elements ==================== */
.anyhave-form-group {
    margin-bottom: 18px;
}
.anyhave-form-group label {
    display: block;
    font-size: 13px;
    color: var(--anyhave-text-light);
    margin-bottom: 6px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}
.anyhave-form-group input,
.anyhave-form-group select,
.anyhave-form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid #E0D8CC;
    border-radius: var(--radius);
    font-size: 15px;
    font-family: inherit;
    color: var(--anyhave-text);
    background: var(--anyhave-white);
    transition: var(--transition);
    outline: none;
}
.anyhave-form-group input:focus,
.anyhave-form-group select:focus,
.anyhave-form-group textarea:focus {
    border-color: var(--anyhave-gold);
    box-shadow: 0 0 0 3px rgba(200,169,110,0.15);
}
.anyhave-form-group textarea { resize: vertical; min-height: 80px; }

.anyhave-btn {
    width: 100%;
    padding: 14px 24px;
    border: none;
    border-radius: var(--radius);
    font-size: 15px;
    font-family: inherit;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 600;
}
.anyhave-btn-primary {
    background: var(--anyhave-gold);
    color: white;
}
.anyhave-btn-primary:hover {
    background: var(--anyhave-gold-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}
.anyhave-btn-outline {
    background: transparent;
    color: var(--anyhave-gold);
    border: 1.5px solid var(--anyhave-gold);
}
.anyhave-btn-outline:hover {
    background: var(--anyhave-gold);
    color: white;
}

/* ==================== Trust Strip ==================== */
.anyhave-trust-strip {
    display: flex;
    justify-content: center;
    gap: 24px;
    padding: 16px 36px;
    border-top: 1px solid #E8E0D4;
    background: var(--anyhave-cream);
}
.anyhave-trust-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--anyhave-text-light);
}
.anyhave-trust-item .icon { font-size: 16px; }

/* ==================== Success State ==================== */
.anyhave-success {
    text-align: center;
    padding: 40px 20px;
}
.anyhave-success .icon { font-size: 56px; margin-bottom: 16px; }
.anyhave-success h2 { font-size: 24px; color: var(--anyhave-gold-dark); }
.anyhave-success p { color: var(--anyhave-text-light); margin: 12px 0; }

/* ==================== CAD Booking ==================== */
.anyhave-booking {
    width: 90%;
    max-width: 680px;
}
.anyhave-booking .anyhave-popup-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
}
.anyhave-booking .booking-left {
    padding-right: 20px;
    border-right: 1px solid #E8E0D4;
}
.anyhave-booking .booking-right {
    padding-left: 20px;
}

.anyhave-calendar {
    margin-top: 12px;
}
.anyhave-calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}
.anyhave-calendar-header button {
    background: none; border: none; cursor: pointer;
    font-size: 18px; color: var(--anyhave-gold);
    padding: 4px 8px;
}
.anyhave-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    text-align: center;
}
.anyhave-calendar-grid .day-header {
    font-size: 11px;
    color: var(--anyhave-text-light);
    padding: 6px 0;
    text-transform: uppercase;
}
.anyhave-calendar-grid .day {
    padding: 10px 4px;
    font-size: 14px;
    cursor: pointer;
    border-radius: var(--radius);
    transition: var(--transition);
}
.anyhave-calendar-grid .day:hover { background: var(--anyhave-cream); }
.anyhave-calendar-grid .day.selected { background: var(--anyhave-gold); color: white; }
.anyhave-calendar-grid .day.disabled { color: #CCC; cursor: not-allowed; pointer-events: none; }
.anyhave-calendar-grid .day.today { font-weight: 700; }

.anyhave-time-slots {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 12px;
}
.anyhave-time-slot {
    padding: 10px 8px;
    text-align: center;
    border: 1.5px solid #E0D8CC;
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 13px;
    transition: var(--transition);
}
.anyhave-time-slot:hover { border-color: var(--anyhave-gold); }
.anyhave-time-slot.selected { background: var(--anyhave-gold); color: white; border-color: var(--anyhave-gold); }

.anyhave-booking-summary {
    background: var(--anyhave-cream);
    padding: 16px;
    border-radius: var(--radius);
    margin-top: 16px;
    font-size: 14px;
}
.anyhave-booking-summary .item { display: flex; justify-content: space-between; padding: 6px 0; }
.anyhave-booking-summary .item span:first-child { color: var(--anyhave-text-light); }

/* ==================== Step Indicator ==================== */
.anyhave-steps {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 24px;
}
.anyhave-step-dot {
    width: 10px; height: 10px;
    border-radius: 50%;
    background: #E0D8CC;
    transition: var(--transition);
}
.anyhave-step-dot.active { background: var(--anyhave-gold); }
.anyhave-step-dot.done { background: var(--anyhave-gold-dark); }

/* ==================== Responsive ==================== */
@media (max-width: 600px) {
    .anyhave-popup { width: 95%; max-width: 100%; }
    .anyhave-popup-header { padding: 24px 20px 20px; }
    .anyhave-popup-header h2 { font-size: 22px; }
    .anyhave-popup-body { padding: 20px; }
    .anyhave-trust-strip { gap: 12px; padding: 12px 20px; flex-wrap: wrap; }
    .anyhave-booking .anyhave-popup-body { grid-template-columns: 1fr; }
    .anyhave-booking .booking-left { border-right: none; padding-right: 0; border-bottom: 1px solid #E8E0D4; padding-bottom: 20px; margin-bottom: 20px; }
    .anyhave-booking .booking-right { padding-left: 0; }
}
