/* ========================================
   ARAB MONETARY GATE - STYLE SYSTEM
   Premium Currency Exchange Website
   ======================================== */

/* ========================================
   1. CSS CUSTOM PROPERTIES (Design Tokens)
   ======================================== */
:root {
    /* Brand Colors - Extracted from Logo (Updated) */
    --color-gold: #D4AF37;
    --color-gold-light: #E8D5A3;
    --color-gold-dark: #B8860B;
    --color-gold-shimmer: linear-gradient(135deg, #D4AF37 0%, #E8D5A3 50%, #D4AF37 100%);

    --color-teal: #1A5F5F;
    --color-teal-light: #2A7A7A;
    --color-teal-dark: #0F4040;

    /* Neutrals */
    --color-white: #FFFFFF;
    --color-off-white: #F8F6F0;
    --color-cream: #FDF9F0;
    --color-gray-100: #F5F5F5;
    --color-gray-200: #EEEEEE;
    --color-gray-300: #E0E0E0;
    --color-gray-400: #BDBDBD;
    --color-gray-500: #9E9E9E;
    --color-gray-600: #757575;
    --color-gray-700: #616161;
    --color-gray-800: #424242;
    --color-gray-900: #2D3436;
    --color-black: #1A1A1A;

    /* Semantic Colors */
    --color-success: #10B981;
    --color-error: #EF4444;
    --color-warning: #F59E0B;
    --color-info: #3B82F6;

    /* Typography */
    --font-arabic: 'Cairo', 'Segoe UI', Tahoma, sans-serif;
    --font-english: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

    --text-xs: 0.75rem;
    --text-sm: 0.875rem;
    --text-base: 1rem;
    --text-lg: 1.125rem;
    --text-xl: 1.25rem;
    --text-2xl: 1.5rem;
    --text-3xl: 1.875rem;
    --text-4xl: 2.25rem;
    --text-5xl: 3rem;
    --text-6xl: 3.75rem;

    /* Spacing */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;
    --space-24: 6rem;

    /* Border Radius */
    --radius-sm: 0.25rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --shadow-gold: 0 4px 20px rgba(197, 163, 73, 0.25);
    --shadow-teal: 0 4px 20px rgba(29, 111, 111, 0.25);

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
    --transition-slow: 350ms ease;
    --transition-bounce: 500ms cubic-bezier(0.68, -0.55, 0.265, 1.55);

    /* Z-Index Scale */
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-fixed: 300;
    --z-modal: 400;
    --z-tooltip: 500;
}

/* ========================================
   DARK MODE THEME
   ======================================== */
[data-theme="dark"] {
    --color-white: #0D1117;
    --color-off-white: #161B22;
    --color-cream: #1C2128;
    --color-gray-100: #21262D;
    --color-gray-200: #30363D;
    --color-gray-300: #484F58;
    --color-gray-400: #6E7681;
    --color-gray-500: #8B949E;
    --color-gray-600: #C9D1D9;
    --color-gray-700: #E6EDF3;
    --color-gray-800: #F0F6FC;
    --color-gray-900: #FFFFFF;
    --color-black: #FFFFFF;

    /* Enhanced shadows for dark mode */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -1px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -2px rgba(0, 0, 0, 0.3);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

/* Dark mode specific overrides */
[data-theme="dark"] .header.scrolled {
    background: rgba(13, 17, 23, 0.95);
}

[data-theme="dark"] .hero-bg {
    background: linear-gradient(135deg, #0D1117 0%, #161B22 50%, #1C2128 100%);
}

[data-theme="dark"] .hero-pattern {
    background-image:
        radial-gradient(circle at 20% 80%, rgba(197, 163, 73, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(29, 111, 111, 0.12) 0%, transparent 50%);
}

[data-theme="dark"] .currency-converter {
    background: rgba(22, 27, 34, 0.95);
    border-color: var(--color-gray-200);
}

[data-theme="dark"] .smart-card {
    background: var(--color-off-white);
    border-color: var(--color-gray-200);
}

[data-theme="dark"] .smart-card-header {
    background: linear-gradient(135deg, var(--color-gray-100) 0%, var(--color-off-white) 100%);
}

[data-theme="dark"] .gold-section {
    background: linear-gradient(135deg, #1C2128 0%, #161B22 100%);
    border-color: rgba(197, 163, 73, 0.3);
}

[data-theme="dark"] .gold-card {
    background: var(--color-off-white);
    border-color: var(--color-gray-200);
}

[data-theme="dark"] .service-card {
    background: var(--color-off-white);
    border-color: var(--color-gray-200);
}

[data-theme="dark"] .trust-card {
    background: linear-gradient(135deg, var(--color-off-white) 0%, var(--color-cream) 100%);
    border-color: var(--color-gray-200);
}

[data-theme="dark"] .about-visual {
    background: var(--color-off-white);
}

[data-theme="dark"] .info-card {
    background: var(--color-gray-100);
}

[data-theme="dark"] .info-card:hover {
    background: var(--color-off-white);
}

[data-theme="dark"] .contact-form {
    background: var(--color-gray-100);
    border-color: var(--color-gray-200);
}

[data-theme="dark"] .form-group input,
[data-theme="dark"] .form-group textarea,
[data-theme="dark"] .form-group select {
    background: var(--color-off-white);
    border-color: var(--color-gray-200);
    color: var(--color-gray-900);
}

[data-theme="dark"] .input-with-currency {
    background: var(--color-gray-100);
}

[data-theme="dark"] .input-with-currency select {
    background: var(--color-off-white);
    border-color: var(--color-gray-200);
    color: var(--color-gray-900);
}

[data-theme="dark"] .rates-container {
    background: var(--color-off-white);
    border-color: var(--color-gray-200);
}

/* Theme Toggle Button */
.theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: transparent;
    border: 1px solid var(--color-gray-300);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    color: var(--color-gray-700);
}

.theme-toggle:hover {
    background: var(--color-gray-100);
    border-color: var(--color-gold);
    color: var(--color-gold);
}

.theme-toggle svg {
    width: 20px;
    height: 20px;
}

.theme-toggle .icon-moon {
    display: none;
}

[data-theme="dark"] .theme-toggle .icon-sun {
    display: none;
}

[data-theme="dark"] .theme-toggle .icon-moon {
    display: block;
}

/* ========================================
   NEWS TICKER STYLES
   ======================================== */
.news-ticker {
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    z-index: var(--z-sticky);
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, var(--color-gray-900) 0%, #1a2634 100%);
    border-bottom: 2px solid var(--color-gold);
    overflow: hidden;
}

.header.scrolled~.news-ticker,
.news-ticker.scrolled {
    top: 68px;
}

.ticker-label {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-6);
    background: linear-gradient(135deg, var(--color-gold) 0%, var(--color-gold-dark) 100%);
    color: var(--color-white);
    font-weight: 700;
    font-size: var(--text-sm);
    white-space: nowrap;
}

.ticker-icon {
    font-size: var(--text-lg);
}

.ticker-wrapper {
    flex: 1;
    overflow: hidden;
    padding: var(--space-3) 0;
}

.ticker-content {
    display: flex;
    align-items: center;
    gap: var(--space-6);
    padding-right: var(--space-6);
    /* Speed optimized for readability (30s) */
    animation: ticker-scroll 20s linear infinite;
    white-space: nowrap;
    will-change: transform;
}

.ticker-item {
    color: var(--color-white);
    font-size: var(--text-sm);
    font-weight: 500;
}

.ticker-separator {
    color: var(--color-gold);
    font-size: var(--text-xs);
}

@keyframes ticker-scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(50%);
    }
}

.news-ticker:hover .ticker-content {
    animation-play-state: paused;
}

@media (max-width: 768px) {
    .news-ticker {
        top: 70px;
    }

    .ticker-label {
        padding: var(--space-2) var(--space-4);
        font-size: var(--text-xs);
    }

    .ticker-label span:last-child {
        display: none;
    }

    .ticker-item {
        font-size: 0.8rem;
        /* Slightly larger for readability */
        padding: 0 5px;
    }

    /* Optimize speed for mobile */
    .ticker-content {
        animation-duration: 15s;
        gap: var(--space-4);
        padding-right: var(--space-4);
    }
}

/* ========================================
   2. CSS RESET & BASE STYLES
   ======================================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-arabic);
    font-size: var(--text-base);
    line-height: 1.7;
    color: var(--color-gray-900);
    background-color: var(--color-off-white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font-family: inherit;
    font-size: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

ul,
ol {
    list-style: none;
}

input,
textarea,
select {
    font-family: inherit;
    font-size: inherit;
}

/* Focus Styles for Accessibility */
:focus-visible {
    outline: 2px solid var(--color-gold);
    outline-offset: 2px;
}

/* Skip Link */
.skip-link {
    position: absolute;
    top: -100%;
    left: 50%;
    transform: translateX(-50%);
    padding: var(--space-3) var(--space-6);
    background: var(--color-gold);
    color: var(--color-white);
    border-radius: var(--radius-md);
    font-weight: 600;
    z-index: var(--z-tooltip);
    transition: top var(--transition-fast);
}

.skip-link:focus {
    top: var(--space-4);
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    html {
        scroll-behavior: auto;
    }
}

/* ========================================
   3. LAYOUT UTILITIES
   ======================================== */
.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 var(--space-6);
}

@media (max-width: 768px) {
    .container {
        padding: 0 var(--space-4);
    }
}

/* ========================================
   4. TYPOGRAPHY UTILITIES
   ======================================== */
.text-gradient {
    background: linear-gradient(135deg, var(--color-gold) 0%, var(--color-gold-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ========================================
   5. BUTTON COMPONENTS
   ======================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-6);
    font-weight: 600;
    font-size: var(--text-sm);
    border-radius: var(--radius-lg);
    transition: all var(--transition-base);
    cursor: pointer;
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-gold) 0%, var(--color-gold-dark) 100%);
    color: var(--color-white);
    box-shadow: var(--shadow-gold);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(197, 163, 73, 0.35);
}

.btn-outline {
    background: transparent;
    color: var(--color-teal);
    border: 2px solid var(--color-teal);
}

.btn-outline:hover {
    background: var(--color-teal);
    color: var(--color-white);
}

.btn-ghost {
    background: transparent;
    color: var(--color-gray-600);
}

.btn-ghost:hover {
    background: var(--color-gray-100);
    color: var(--color-gray-900);
}

.btn-lg {
    padding: var(--space-4) var(--space-8);
    font-size: var(--text-base);
}

.btn-sm {
    padding: var(--space-2) var(--space-4);
    font-size: var(--text-xs);
}

.btn-block {
    width: 100%;
}

.btn-icon {
    width: 1.25em;
    height: 1.25em;
}

/* ========================================
   6. HEADER & NAVIGATION
   ======================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: var(--z-fixed);
    padding: var(--space-4) 0;
    transition: all var(--transition-base);
}

.header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-md);
    padding: var(--space-3) 0;
}

.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-8);
}

.logo {
    display: flex;
    align-items: center;
}

.logo-img {
    height: 60px;
    width: auto;
    transition: transform var(--transition-base);
}

.header.scrolled .logo-img {
    height: 50px;
}

.logo:hover .logo-img {
    transform: scale(1.05);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: var(--space-8);
}

.nav-link {
    position: relative;
    font-weight: 500;
    color: var(--color-gray-700);
    padding: var(--space-2);
    transition: color var(--transition-fast);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 0;
    height: 2px;
    background: var(--color-gold);
    transition: width var(--transition-base);
}

.nav-link:hover,
.nav-link.active {
    color: var(--color-gold);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: var(--space-4);
}

.lang-toggle {
    padding: var(--space-2) var(--space-3);
    font-weight: 600;
    font-size: var(--text-sm);
    color: var(--color-teal);
    border: 1px solid var(--color-teal);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.lang-toggle:hover {
    background: var(--color-teal);
    color: var(--color-white);
}

/* Mobile Menu */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: var(--space-2);
}

.hamburger {
    position: relative;
    width: 24px;
    height: 2px;
    background: var(--color-gray-700);
    border-radius: 2px;
    transition: background var(--transition-fast);
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: inherit;
    border-radius: inherit;
    transition: transform var(--transition-fast);
}

.hamburger::before {
    top: -8px;
}

.hamburger::after {
    top: 8px;
}

.mobile-menu-btn[aria-expanded="true"] .hamburger {
    background: transparent;
}

.mobile-menu-btn[aria-expanded="true"] .hamburger::before {
    transform: translateY(8px) rotate(45deg);
    background: var(--color-gray-700);
}

.mobile-menu-btn[aria-expanded="true"] .hamburger::after {
    transform: translateY(-8px) rotate(-45deg);
    background: var(--color-gray-700);
}

@media (max-width: 992px) {
    .nav-links {
        position: fixed;
        top: 80px;
        right: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        flex-direction: column;
        justify-content: flex-start;
        padding: var(--space-8);
        background: var(--color-white);
        transition: right var(--transition-base);
    }

    .nav-links.active {
        right: 0;
    }

    .nav-link {
        font-size: var(--text-lg);
        padding: var(--space-4);
    }

    .mobile-menu-btn {
        display: flex;
    }

    .nav-actions .btn-primary {
        display: none;
    }
}

/* ========================================
   7. HERO SECTION
   ======================================== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: calc(var(--space-24) + 60px) 0 var(--space-16);
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--color-cream) 0%, var(--color-off-white) 50%, var(--color-white) 100%);
    z-index: -2;
}

.hero-pattern {
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 20% 80%, rgba(197, 163, 73, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(29, 111, 111, 0.08) 0%, transparent 50%);
    z-index: -1;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-12);
    align-items: center;
}

.hero-text {
    max-width: 600px;
}

.hero-badge {
    display: inline-block;
    padding: var(--space-2) var(--space-4);
    background: rgba(197, 163, 73, 0.1);
    color: var(--color-gold-dark);
    font-size: var(--text-sm);
    font-weight: 600;
    border-radius: var(--radius-full);
    margin-bottom: var(--space-6);
}

.hero-title {
    font-size: clamp(var(--text-2xl), 4vw, var(--text-5xl));
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: var(--space-6);
    color: var(--color-gray-900);
}

.hero-title .company-name {
    display: block;
    color: var(--color-teal);
}

.hero-title .text-gradient {
    display: block;
}

.hero-description {
    font-size: var(--text-lg);
    color: var(--color-gray-600);
    margin-bottom: var(--space-8);
    line-height: 1.8;
}

.hero-actions {
    display: flex;
    gap: var(--space-4);
    flex-wrap: wrap;
    margin-bottom: var(--space-12);
}

.hero-stats {
    display: flex;
    gap: var(--space-10);
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: var(--text-3xl);
    font-weight: 800;
    color: var(--color-teal);
}

.stat-label {
    font-size: var(--text-sm);
    color: var(--color-gray-500);
}

/* Hero Visual Card */
.hero-visual {
    display: flex;
    justify-content: center;
    perspective: 1000px;
}

.hero-card {
    position: relative;
    width: 100%;
    max-width: 400px;
    padding: var(--space-8);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-2xl);
    border: 1px solid rgba(255, 255, 255, 0.5);
    transform: rotateY(-5deg) rotateX(5deg);
    transition: transform var(--transition-slow);
}

.hero-card:hover {
    transform: rotateY(0) rotateX(0);
}

.card-glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(197, 163, 73, 0.15) 0%, transparent 50%);
    animation: glow-rotate 10s linear infinite;
    pointer-events: none;
}

@keyframes glow-rotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.floating-currencies {
    display: flex;
    justify-content: center;
    gap: var(--space-6);
    margin-bottom: var(--space-6);
}

.currency-bubble {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    font-size: var(--text-xl);
    font-weight: 700;
    border-radius: var(--radius-full);
    animation: float 3s ease-in-out infinite;
}

.currency-bubble.usd {
    background: linear-gradient(135deg, #22C55E 0%, #16A34A 100%);
    color: white;
    animation-delay: 0s;
}

.currency-bubble.eur {
    background: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%);
    color: white;
    animation-delay: 0.5s;
}

.currency-bubble.gbp {
    background: linear-gradient(135deg, #8B5CF6 0%, #7C3AED 100%);
    color: white;
    animation-delay: 1s;
}

.currency-bubble.jpy {
    background: linear-gradient(135deg, #EF4444 0%, #DC2626 100%);
    color: white;
    animation-delay: 1.5s;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.exchange-preview {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.exchange-row {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-3) var(--space-4);
    background: var(--color-gray-100);
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
}

.exchange-row:hover {
    background: var(--color-white);
    box-shadow: var(--shadow-md);
}

.exchange-row .flag {
    font-size: var(--text-xl);
}

.exchange-row .currency-name {
    flex: 1;
    font-weight: 500;
    font-size: var(--text-sm);
}

.exchange-row .rate {
    display: flex;
    align-items: center;
    gap: var(--space-1);
    font-weight: 700;
    font-family: var(--font-english);
}

.exchange-row .rate svg {
    width: 16px;
    height: 16px;
    stroke-width: 2;
    stroke: currentColor;
    fill: none;
}

.exchange-row .rate.up {
    color: var(--color-success);
}

.exchange-row .rate.down {
    color: var(--color-error);
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: var(--space-8);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-2);
    color: var(--color-gray-500);
    font-size: var(--text-sm);
    animation: bounce-subtle 2s ease-in-out infinite;
}

.scroll-arrow {
    width: 24px;
    height: 24px;
    border-left: 2px solid var(--color-gray-400);
    border-bottom: 2px solid var(--color-gray-400);
    transform: rotate(-45deg);
}

@keyframes bounce-subtle {

    0%,
    100% {
        transform: translateX(-50%) translateY(0);
    }

    50% {
        transform: translateX(-50%) translateY(10px);
    }
}

@media (max-width: 992px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-text {
        max-width: 100%;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-stats {
        justify-content: center;
    }

    .hero-visual {
        display: none;
    }

    .currency-converter {
        display: block;
    }

    .scroll-indicator {
        display: none;
    }
}

/* ========================================
   CURRENCY CONVERTER STYLES
   ======================================== */
.currency-converter {
    width: 100%;
    max-width: 420px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-2xl);
    border: 1px solid rgba(255, 255, 255, 0.5);
    overflow: hidden;
}

.converter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-4) var(--space-6);
    background: linear-gradient(135deg, var(--color-teal) 0%, var(--color-teal-dark) 100%);
    color: var(--color-white);
}

.converter-header h3 {
    font-size: var(--text-lg);
    font-weight: 700;
    margin: 0;
}

.market-selector {
    display: flex;
    gap: var(--space-2);
}

.market-btn {
    padding: var(--space-2) var(--space-3);
    font-size: var(--text-xs);
    font-weight: 600;
    background: rgba(255, 255, 255, 0.15);
    color: var(--color-white);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    cursor: pointer;
    border: none;
}

.market-btn:hover {
    background: rgba(255, 255, 255, 0.25);
}

.market-btn.active {
    background: var(--color-gold);
    color: var(--color-white);
}

.converter-body {
    padding: var(--space-6);
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.converter-input-group {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

.converter-input-group label {
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-gray-600);
}

.input-with-currency {
    display: flex;
    gap: var(--space-2);
    background: var(--color-gray-100);
    border-radius: var(--radius-lg);
    padding: var(--space-2);
    border: 2px solid transparent;
    transition: all var(--transition-fast);
}

.input-with-currency:focus-within {
    border-color: var(--color-gold);
    background: var(--color-white);
    box-shadow: 0 0 0 3px rgba(197, 163, 73, 0.1);
}

.input-with-currency input {
    flex: 1;
    background: transparent;
    border: none;
    padding: var(--space-3);
    font-size: var(--text-xl);
    font-weight: 700;
    font-family: var(--font-english);
    color: var(--color-gray-900);
    min-width: 0;
}

.input-with-currency input:focus {
    outline: none;
}

.input-with-currency input[readonly] {
    color: var(--color-teal);
}

.input-with-currency select {
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--radius-md);
    padding: var(--space-2) var(--space-3);
    font-size: var(--text-sm);
    font-weight: 600;
    cursor: pointer;
    min-width: 100px;
}

.converter-swap {
    display: flex;
    justify-content: center;
}

.swap-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--color-gold) 0%, var(--color-gold-dark) 100%);
    color: var(--color-white);
    border-radius: var(--radius-full);
    cursor: pointer;
    border: none;
    transition: all var(--transition-base);
    box-shadow: var(--shadow-gold);
}

.swap-btn:hover {
    transform: rotate(180deg) scale(1.05);
}

.swap-btn svg {
    width: 20px;
    height: 20px;
}

.converter-footer {
    padding: var(--space-3) var(--space-6);
    background: var(--color-gray-50);
    border-top: 1px solid var(--color-gray-200);
}

.rate-info {
    font-size: var(--text-sm);
    color: var(--color-gray-500);
}

@media (max-width: 992px) {
    .currency-converter {
        max-width: 100%;
        margin-top: var(--space-8);
    }
}

/* ========================================
   8. SECTION HEADERS
   ======================================== */
.section-header {
    text-align: center;
    max-width: 600px;
    margin: 0 auto var(--space-12);
}

.section-badge {
    display: inline-block;
    padding: var(--space-2) var(--space-4);
    background: linear-gradient(135deg, rgba(197, 163, 73, 0.1) 0%, rgba(197, 163, 73, 0.05) 100%);
    color: var(--color-gold-dark);
    font-size: var(--text-sm);
    font-weight: 600;
    border-radius: var(--radius-full);
    margin-bottom: var(--space-4);
    border: 1px solid rgba(197, 163, 73, 0.2);
}

.section-title {
    font-size: clamp(var(--text-2xl), 4vw, var(--text-4xl));
    font-weight: 800;
    color: var(--color-gray-900);
    margin-bottom: var(--space-4);
    line-height: 1.3;
}

.section-description {
    font-size: var(--text-lg);
    color: var(--color-gray-600);
    line-height: 1.7;
}

/* ========================================
   9. RATES SECTION
   ======================================== */
.rates {
    padding: var(--space-20) 0;
    background: var(--color-white);
}

.rates-container {
    background: var(--color-white);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-xl);
    overflow: hidden;
    border: 1px solid var(--color-gray-200);
}

.rates-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-6);
    background: linear-gradient(135deg, var(--color-teal) 0%, var(--color-teal-dark) 100%);
    color: var(--color-white);
}

.last-update {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-size: var(--text-sm);
    opacity: 0.9;
}

.last-update svg {
    width: 18px;
    height: 18px;
}

.rates-actions .btn-ghost {
    color: var(--color-white);
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.rates-actions .btn-ghost:hover {
    background: rgba(255, 255, 255, 0.1);
}

.rates-actions svg {
    width: 16px;
    height: 16px;
}

.rates-table-wrapper {
    overflow-x: auto;
}

.rates-table {
    width: 100%;
    border-collapse: collapse;
}

.rates-table th,
.rates-table td {
    padding: var(--space-4) var(--space-6);
    text-align: right;
}

.rates-table th {
    background: var(--color-gray-100);
    font-weight: 600;
    font-size: var(--text-sm);
    color: var(--color-gray-600);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.rate-row {
    transition: background var(--transition-fast);
    border-bottom: 1px solid var(--color-gray-100);
}

.rate-row:hover {
    background: var(--color-gray-50);
}

.rate-row:last-child {
    border-bottom: none;
}

.currency-info {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.flag-lg {
    font-size: var(--text-2xl);
}

.currency-code {
    display: inline-block;
    padding: var(--space-1) var(--space-2);
    background: var(--color-gray-200);
    font-family: var(--font-english);
    font-weight: 600;
    font-size: var(--text-xs);
    border-radius: var(--radius-sm);
    color: var(--color-gray-700);
}

.price {
    font-family: var(--font-english);
    font-weight: 600;
    font-size: var(--text-lg);
}

.price.buy {
    color: var(--color-success);
}

.price.sell {
    color: var(--color-teal);
}

.change {
    font-family: var(--font-english);
    font-weight: 600;
    font-size: var(--text-sm);
    padding: var(--space-1) var(--space-2);
    border-radius: var(--radius-sm);
}

.change.positive {
    color: var(--color-success);
    background: rgba(16, 185, 129, 0.1);
}

.change.negative {
    color: var(--color-error);
    background: rgba(239, 68, 68, 0.1);
}

.change.neutral {
    color: var(--color-gray-500);
    background: var(--color-gray-100);
}

.rates-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-6);
    background: var(--color-gray-50);
    border-top: 1px solid var(--color-gray-200);
}

.disclaimer {
    font-size: var(--text-sm);
    color: var(--color-gray-500);
}

@media (max-width: 768px) {
    .rates-header {
        flex-direction: column;
        gap: var(--space-4);
        text-align: center;
    }

    .rates-footer {
        flex-direction: column;
        gap: var(--space-4);
        text-align: center;
    }

    .rates-table th,
    .rates-table td {
        padding: var(--space-3) var(--space-4);
        font-size: var(--text-sm);
    }
}

/* ========================================
   10. SERVICES SECTION
   ======================================== */
.services {
    padding: var(--space-20) 0;
    background: linear-gradient(180deg, var(--color-off-white) 0%, var(--color-white) 100%);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-6);
}

.service-card {
    position: relative;
    padding: var(--space-8);
    background: var(--color-white);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--color-gray-200);
    transition: all var(--transition-base);
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--color-gold) 0%, var(--color-gold-light) 100%);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform var(--transition-base);
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-card.featured {
    grid-column: span 2;
    background: linear-gradient(135deg, var(--color-teal) 0%, var(--color-teal-dark) 100%);
    color: var(--color-white);
    border: none;
}

.service-card.featured::before {
    background: linear-gradient(90deg, var(--color-gold) 0%, var(--color-gold-light) 100%);
}

.service-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--color-gold) 0%, var(--color-gold-light) 100%);
    border-radius: var(--radius-xl);
    margin-bottom: var(--space-6);
}

.service-icon svg {
    width: 28px;
    height: 28px;
    stroke: var(--color-white);
}

.service-card.featured .service-icon {
    background: rgba(255, 255, 255, 0.2);
}

.service-title {
    font-size: var(--text-xl);
    font-weight: 700;
    margin-bottom: var(--space-3);
}

.service-card.featured .service-title {
    font-size: var(--text-2xl);
}

.service-description {
    color: var(--color-gray-600);
    margin-bottom: var(--space-4);
    line-height: 1.7;
}

.service-card.featured .service-description {
    color: rgba(255, 255, 255, 0.9);
}

.service-features {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-3);
    margin-bottom: var(--space-6);
}

.service-features li {
    padding: var(--space-2) var(--space-3);
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full);
    font-size: var(--text-sm);
}

.service-link {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    color: var(--color-gold);
    font-weight: 600;
    transition: gap var(--transition-fast);
}

.service-link:hover {
    gap: var(--space-3);
}

.service-link svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
}

.service-card.featured .service-link {
    color: var(--color-gold-light);
}

@media (max-width: 768px) {
    .service-card.featured {
        grid-column: span 1;
    }
}

/* ========================================
   11. WHY US SECTION
   ======================================== */
.why-us {
    padding: var(--space-20) 0;
    background: var(--color-white);
}

.why-us-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-16);
    align-items: center;
}

.why-us-text .section-badge {
    justify-self: start;
}

.why-us-text .section-title {
    text-align: start;
}

.why-us-text .section-description {
    text-align: start;
    margin-bottom: var(--space-10);
}

.features-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-6);
}

.feature-item {
    display: flex;
    gap: var(--space-4);
}

.feature-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, rgba(197, 163, 73, 0.1) 0%, rgba(197, 163, 73, 0.05) 100%);
    border-radius: var(--radius-lg);
}

.feature-icon svg {
    width: 24px;
    height: 24px;
    stroke: var(--color-gold);
}

.feature-content h4 {
    font-size: var(--text-lg);
    font-weight: 700;
    color: var(--color-gray-900);
    margin-bottom: var(--space-1);
}

.feature-content p {
    font-size: var(--text-sm);
    color: var(--color-gray-600);
}

/* Trust Card */
.why-us-visual {
    display: flex;
    justify-content: center;
}

.trust-card {
    width: 100%;
    max-width: 400px;
    padding: var(--space-8);
    background: linear-gradient(135deg, var(--color-cream) 0%, var(--color-white) 100%);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--color-gray-200);
}

.trust-badges {
    display: flex;
    justify-content: space-around;
    margin-bottom: var(--space-8);
    padding-bottom: var(--space-8);
    border-bottom: 1px solid var(--color-gray-200);
}

.badge-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-2);
    text-align: center;
}

.badge-icon {
    font-size: var(--text-2xl);
}

.badge-item span {
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--color-gray-600);
}

.testimonial {
    text-align: center;
}

.testimonial p {
    font-size: var(--text-lg);
    font-style: italic;
    color: var(--color-gray-700);
    margin-bottom: var(--space-6);
    line-height: 1.8;
}

.testimonial-author {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-3);
}

.author-avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--color-teal) 0%, var(--color-teal-dark) 100%);
    color: var(--color-white);
    font-weight: 700;
    border-radius: var(--radius-full);
}

.author-info {
    text-align: start;
}

.author-info strong {
    display: block;
    font-weight: 700;
    color: var(--color-gray-900);
}

.author-info span {
    font-size: var(--text-sm);
    color: var(--color-gray-500);
}

@media (max-width: 992px) {
    .why-us-content {
        grid-template-columns: 1fr;
    }

    .why-us-text .section-title,
    .why-us-text .section-description {
        text-align: center;
    }
}

/* ========================================
   12. ABOUT SECTION
   ======================================== */
.about {
    padding: var(--space-20) 0;
    background: linear-gradient(135deg, var(--color-off-white) 0%, var(--color-cream) 100%);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-16);
    align-items: center;
}

.about-image {
    display: flex;
    justify-content: center;
}

.image-frame {
    position: relative;
    padding: var(--space-4);
}

.image-frame::before {
    content: '';
    position: absolute;
    top: 20px;
    right: 20px;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--color-gold) 0%, var(--color-gold-light) 100%);
    border-radius: var(--radius-2xl);
    z-index: -1;
}

.about-visual {
    position: relative;
    padding: var(--space-12);
    background: var(--color-white);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-xl);
}

.logo-showcase {
    display: flex;
    justify-content: center;
    margin-bottom: var(--space-6);
}

.about-logo {
    max-width: 200px;
    height: auto;
}

.years-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: var(--space-4);
    background: linear-gradient(135deg, var(--color-teal) 0%, var(--color-teal-dark) 100%);
    color: var(--color-white);
    border-radius: var(--radius-xl);
    text-align: center;
}

.years-number {
    font-size: var(--text-4xl);
    font-weight: 800;
    line-height: 1;
}

.years-text {
    font-size: var(--text-sm);
    opacity: 0.9;
}

.about-text .section-badge {
    display: inline-block;
}

.about-text .section-title {
    text-align: start;
    margin-bottom: var(--space-6);
}

.about-description {
    color: var(--color-gray-600);
    margin-bottom: var(--space-4);
    line-height: 1.8;
}

.about-values {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-4);
    margin-top: var(--space-8);
}

.value-item {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-4);
    background: var(--color-white);
    border-radius: var(--radius-full);
    box-shadow: var(--shadow-sm);
}

.value-icon {
    font-size: var(--text-lg);
}

.value-text {
    font-weight: 600;
    color: var(--color-gray-700);
}

@media (max-width: 992px) {
    .about-content {
        grid-template-columns: 1fr;
    }

    .about-image {
        order: -1;
    }

    .about-text .section-title {
        text-align: center;
    }

    .about-description {
        text-align: center;
    }

    .about-values {
        justify-content: center;
    }
}

/* ========================================
   13. CONTACT SECTION
   ======================================== */
.contact {
    padding: var(--space-20) 0;
    background: var(--color-white);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-12);
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.info-card {
    display: flex;
    gap: var(--space-4);
    padding: var(--space-6);
    background: var(--color-gray-50);
    border-radius: var(--radius-xl);
    transition: all var(--transition-base);
}

.info-card:hover {
    background: var(--color-white);
    box-shadow: var(--shadow-lg);
}

.info-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--color-teal) 0%, var(--color-teal-dark) 100%);
    border-radius: var(--radius-lg);
}

.info-icon svg {
    width: 24px;
    height: 24px;
    stroke: var(--color-white);
}

.info-content h4 {
    font-size: var(--text-lg);
    font-weight: 700;
    color: var(--color-gray-900);
    margin-bottom: var(--space-2);
}

.info-content p {
    font-size: var(--text-sm);
    color: var(--color-gray-600);
    line-height: 1.6;
}

/* Contact Form */
.contact-form {
    padding: var(--space-8);
    background: var(--color-gray-50);
    border-radius: var(--radius-2xl);
    border: 1px solid var(--color-gray-200);
}

.form-group {
    margin-bottom: var(--space-5);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-4);
}

.form-group label {
    display: block;
    font-weight: 600;
    color: var(--color-gray-700);
    margin-bottom: var(--space-2);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: var(--space-4);
    background: var(--color-white);
    border: 2px solid var(--color-gray-200);
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--color-gold);
    box-shadow: 0 0 0 3px rgba(197, 163, 73, 0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--color-gray-400);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.contact-form .btn {
    margin-top: var(--space-4);
}

.contact-form .btn svg {
    width: 20px;
    height: 20px;
}

@media (max-width: 992px) {
    .contact-content {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }
}

/* ========================================
   14. FOOTER
   ======================================== */
.footer {
    padding: var(--space-16) 0 var(--space-8);
    background: linear-gradient(135deg, var(--color-gray-900) 0%, var(--color-black) 100%);
    color: var(--color-white);
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 3fr;
    gap: var(--space-12);
    padding-bottom: var(--space-12);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-brand {
    max-width: 300px;
}

.footer-logo {
    height: 70px;
    width: auto;
    margin-bottom: var(--space-4);
    filter: brightness(0) invert(1);
}

.footer-description {
    color: var(--color-gray-400);
    margin-bottom: var(--space-6);
    line-height: 1.7;
}

.social-links {
    display: flex;
    gap: var(--space-3);
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
}

.social-link:hover {
    background: var(--color-gold);
    transform: translateY(-3px);
}

.social-link svg {
    width: 18px;
    height: 18px;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-8);
}

.footer-column h4 {
    font-size: var(--text-lg);
    font-weight: 700;
    margin-bottom: var(--space-4);
    color: var(--color-gold);
}

.footer-column ul {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.footer-column a {
    color: var(--color-gray-400);
    font-size: var(--text-sm);
    transition: color var(--transition-fast);
}

.footer-column a:hover {
    color: var(--color-white);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--space-8);
}

.footer-bottom p {
    font-size: var(--text-sm);
    color: var(--color-gray-500);
}

.footer-badges {
    display: flex;
    gap: var(--space-4);
}

.footer-badges .badge {
    padding: var(--space-2) var(--space-4);
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-full);
    font-size: var(--text-sm);
    color: var(--color-gray-400);
}

@media (max-width: 992px) {
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-brand {
        max-width: 100%;
    }

    .social-links {
        justify-content: center;
    }

    .footer-links {
        grid-template-columns: 1fr;
        gap: var(--space-8);
    }

    .footer-bottom {
        flex-direction: column;
        gap: var(--space-4);
        text-align: center;
    }
}

@media (max-width: 768px) {
    .footer-links {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ========================================
   SPARKLINE CHARTS
   ======================================== */
.sparkline {
    width: 60px;
    height: 24px;
    flex-shrink: 0;
}

.sparkline svg {
    width: 100%;
    height: 100%;
}

.sparkline-line {
    stroke-linecap: round;
    stroke-linejoin: round;
}

.smart-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

@media (max-width: 576px) {
    .sparkline {
        width: 50px;
        height: 20px;
    }
}

/* ========================================
   MOBILE BOTTOM NAVIGATION
   ======================================== */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: var(--z-modal);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-top: 1px solid var(--color-gray-200);
    padding: var(--space-2) var(--space-4);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] .mobile-bottom-nav {
    background: rgba(22, 27, 34, 0.95);
    border-color: var(--color-gray-200);
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: var(--space-2);
    color: var(--color-gray-500);
    text-decoration: none;
    background: none;
    border: none;
    flex: 1;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.mobile-nav-item .nav-icon {
    font-size: 1.5rem;
    line-height: 1;
}

.mobile-nav-item .nav-text {
    font-size: 0.75rem;
    font-weight: 600;
}

.mobile-nav-item:hover,
.mobile-nav-item.active {
    color: var(--color-gold);
}

@media (max-width: 768px) {
    .mobile-bottom-nav {
        display: flex;
        justify-content: space-around;
    }

    /* Adjust floating buttons to sit above the nav bar */
    .whatsapp-float {
        bottom: 80px;
    }

    .scroll-to-top {
        bottom: 80px;
    }

    /* Increase touch targets globally for mobile */
    button,
    a,
    input,
    select {
        min-height: 44px;
        min-width: 44px;
    }

    /* Adjust body padding for bottom nav */
    body {
        padding-bottom: 70px;
    }
}

/* ========================================
   WHATSAPP FLOATING BUTTON
   ======================================== */
.whatsapp-float {
    position: fixed;
    bottom: var(--space-8);
    left: var(--space-6);
    z-index: var(--z-fixed);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
    color: var(--color-white);
    border-radius: var(--radius-full);
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    transition: all var(--transition-base);
    animation: whatsapp-pulse 2s ease-in-out infinite;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(37, 211, 102, 0.5);
    animation: none;
}

.whatsapp-float svg {
    width: 32px;
    height: 32px;
}

.whatsapp-tooltip {
    position: absolute;
    left: 75px;
    padding: var(--space-2) var(--space-4);
    background: var(--color-gray-900);
    color: var(--color-white);
    font-size: var(--text-sm);
    font-weight: 600;
    border-radius: var(--radius-md);
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-fast);
}

.whatsapp-tooltip::before {
    content: '';
    position: absolute;
    right: 100%;
    top: 50%;
    transform: translateY(-50%);
    border: 6px solid transparent;
    border-left-color: var(--color-gray-900);
    border-right-width: 0;
}

.whatsapp-float:hover .whatsapp-tooltip {
    opacity: 1;
    visibility: visible;
}

@keyframes whatsapp-pulse {

    0%,
    100% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    }

    50% {
        box-shadow: 0 4px 30px rgba(37, 211, 102, 0.6), 0 0 0 15px rgba(37, 211, 102, 0.1);
    }
}

@media (max-width: 768px) {
    .whatsapp-float {
        width: 56px;
        height: 56px;
        bottom: var(--space-6);
        left: var(--space-4);
    }

    .whatsapp-float svg {
        width: 28px;
        height: 28px;
    }

    .whatsapp-tooltip {
        display: none;
    }
}

/* ========================================
   15. ANIMATIONS & EFFECTS
   ======================================== */

/* Shimmer Effect */
@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

.shimmer {
    background: linear-gradient(90deg,
            var(--color-gold) 0%,
            var(--color-gold-light) 50%,
            var(--color-gold) 100%);
    background-size: 200% 100%;
    animation: shimmer 2s linear infinite;
}

/* Fade In Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease forwards;
}

/* Pulse Animation */
@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.pulse {
    animation: pulse 2s ease-in-out infinite;
}

/* ========================================
   18. SMART RATES GRID (Cards)
   ======================================== */
.smart-rates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-6);
    margin-bottom: var(--space-8);
}

.smart-card {
    background: var(--color-white);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--color-gray-200);
    overflow: hidden;
    transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.smart-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: var(--color-gold);
}

.smart-card-header {
    background: linear-gradient(135deg, var(--color-gray-50) 0%, var(--color-white) 100%);
    padding: var(--space-4) var(--space-6);
    border-bottom: 1px solid var(--color-gray-100);
}

.currency-main {
    display: flex;
    align-items: center;
    gap: var(--space-4);
}

.flag-xl {
    font-size: var(--text-3xl);
}

.currency-main h3 {
    font-size: var(--text-lg);
    font-weight: 700;
    color: var(--color-gray-900);
    margin: 0;
}

.currency-main .currency-code {
    font-size: var(--text-sm);
    color: var(--color-gray-500);
    font-weight: 600;
}

.markets-data {
    padding: var(--space-2);
}

.market-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-3) var(--space-4);
    border-bottom: 1px solid var(--color-gray-50);
}

.market-row:last-child {
    border-bottom: none;
}

.market-name {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-weight: 600;
    font-size: var(--text-sm);
    min-width: 80px;
}

.sanaa-market .market-name {
    color: var(--color-gold-dark);
}

.aden-market .market-name {
    color: var(--color-teal);
}

.market-icon {
    font-size: var(--text-lg);
}

.market-values {
    display: flex;
    gap: var(--space-4);
}

.value-box {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.value-label {
    font-size: 10px;
    color: var(--color-gray-400);
    margin-bottom: 2px;
}

.value-num {
    font-family: var(--font-english);
    font-weight: 700;
    font-size: var(--text-base);
}

.value-num.buy {
    color: var(--color-success);
}

.value-num.sell {
    color: var(--color-error);
    /* Red for sell generally implies cost to user or just distinction */
}

/* Override red for sell if needed to match previous theme (Teal was used) */
.value-num.sell {
    color: var(--color-teal);
}

@media (max-width: 576px) {
    .smart-rates-grid {
        grid-template-columns: 1fr;
    }

    .market-row {
        flex-direction: row;
        /* Keep row on mobile for compaction */
        gap: var(--space-2);
    }
}

.rates-tabs-container {
    display: flex;
    justify-content: center;
    margin-bottom: var(--space-6);
}

.rates-tabs {
    display: inline-flex;
    background: var(--color-gray-100);
    padding: var(--space-1);
    border-radius: var(--radius-xl);
    gap: var(--space-1);
}

.rates-tab {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-6);
    font-weight: 600;
    font-size: var(--text-base);
    color: var(--color-gray-600);
    background: transparent;
    border-radius: var(--radius-lg);
    transition: all var(--transition-base);
    cursor: pointer;
}

.rates-tab:hover {
    color: var(--color-gray-900);
}

.rates-tab.active {
    background: var(--color-white);
    color: var(--color-teal);
    box-shadow: var(--shadow-md);
}

.tab-icon {
    font-size: var(--text-lg);
}

.tab-text {
    font-weight: 600;
}

/* City Indicator Badge */
.rates-city-indicator {
    display: flex;
    align-items: center;
}

.city-badge {
    padding: var(--space-2) var(--space-4);
    font-weight: 700;
    font-size: var(--text-sm);
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.2);
}

.city-badge.sanaa {
    background: linear-gradient(135deg, rgba(197, 163, 73, 0.3) 0%, rgba(197, 163, 73, 0.1) 100%);
    color: var(--color-gold-light);
}

.city-badge.aden {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.3) 0%, rgba(59, 130, 246, 0.1) 100%);
    color: #93C5FD;
}

/* Rates Panels */
.rates-panel {
    display: none;
}

.rates-panel.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

/* YER Label in Table Headers */
.yer-label {
    font-size: var(--text-xs);
    opacity: 0.8;
    font-weight: 500;
}

/* ========================================
   17. GOLD PRICES SECTION
   ======================================== */
.gold-section {
    margin-top: var(--space-12);
    padding: var(--space-8);
    background: linear-gradient(135deg, #FEF9E7 0%, #FDF5E6 100%);
    border-radius: var(--radius-2xl);
    border: 1px solid rgba(197, 163, 73, 0.2);
}

.gold-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-8);
}

.gold-title {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.gold-icon {
    font-size: var(--text-3xl);
}

.gold-title h3 {
    font-size: var(--text-2xl);
    font-weight: 800;
    color: var(--color-gray-900);
    margin: 0;
}

.gold-update {
    font-size: var(--text-sm);
    color: var(--color-gray-500);
}

/* Gold Cards Grid */
.gold-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-4);
    margin-bottom: var(--space-6);
}

.gold-card {
    position: relative;
    padding: var(--space-6);
    background: var(--color-white);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--color-gray-200);
    transition: all var(--transition-base);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.gold-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.gold-card.featured {
    background: linear-gradient(135deg, var(--color-gold) 0%, var(--color-gold-dark) 100%);
    color: var(--color-white);
    border: none;
}

.gold-card.featured:hover {
    box-shadow: var(--shadow-gold);
}

.featured-badge {
    position: absolute;
    top: -10px;
    right: 50%;
    transform: translateX(50%);
    padding: var(--space-1) var(--space-3);
    background: var(--color-teal);
    color: var(--color-white);
    font-size: var(--text-xs);
    font-weight: 700;
    border-radius: var(--radius-full);
    white-space: nowrap;
}

/* Gold Karat Badge */
.gold-karat {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: var(--space-4);
}

.karat-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    font-size: var(--text-xl);
    font-weight: 800;
    border-radius: var(--radius-full);
    font-family: var(--font-english);
}

.karat-badge.k24 {
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: var(--color-white);
}

.karat-badge.k22 {
    background: linear-gradient(135deg, #DAA520 0%, #B8860B 100%);
    color: var(--color-white);
}

.karat-badge.k21 {
    background: rgba(255, 255, 255, 0.3);
    color: var(--color-white);
}

.gold-card.featured .karat-badge.k21 {
    background: rgba(255, 255, 255, 0.25);
}

.karat-badge.k18 {
    background: linear-gradient(135deg, #CD853F 0%, #8B4513 100%);
    color: var(--color-white);
}

.karat-label {
    font-size: var(--text-xs);
    color: var(--color-gray-500);
    margin-top: var(--space-1);
}

.gold-card.featured .karat-label {
    color: rgba(255, 255, 255, 0.8);
}

/* Gold Info */
.gold-info {
    margin-bottom: var(--space-4);
}

.gold-name {
    display: block;
    font-size: var(--text-base);
    font-weight: 700;
    color: var(--color-gray-900);
    margin-bottom: var(--space-1);
}

.gold-card.featured .gold-name {
    color: var(--color-white);
}

.gold-desc {
    font-size: var(--text-xs);
    color: var(--color-gray-500);
}

.gold-card.featured .gold-desc {
    color: rgba(255, 255, 255, 0.8);
}

/* Gold Prices */
.gold-prices {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
    width: 100%;
    margin-bottom: var(--space-3);
}

.gold-price-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-2) var(--space-3);
    background: var(--color-gray-50);
    border-radius: var(--radius-md);
}

.gold-card.featured .gold-price-item {
    background: rgba(255, 255, 255, 0.15);
}

.price-label {
    font-size: var(--text-xs);
    color: var(--color-gray-500);
}

.gold-card.featured .price-label {
    color: rgba(255, 255, 255, 0.7);
}

.price-value {
    font-family: var(--font-english);
    font-weight: 700;
    font-size: var(--text-base);
}

.price-value.buy {
    color: var(--color-success);
}

.price-value.sell {
    color: var(--color-teal);
}

.gold-card.featured .price-value {
    color: var(--color-white);
}

.price-unit {
    font-size: var(--text-xs);
    color: var(--color-gray-400);
}

.gold-card.featured .price-unit {
    color: rgba(255, 255, 255, 0.6);
}

/* Gold Change Indicator */
.gold-change {
    display: flex;
    align-items: center;
    gap: var(--space-1);
    font-family: var(--font-english);
    font-weight: 600;
    font-size: var(--text-sm);
    padding: var(--space-1) var(--space-2);
    border-radius: var(--radius-sm);
}

.gold-change svg {
    width: 14px;
    height: 14px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
}

.gold-change.positive {
    color: var(--color-success);
    background: rgba(16, 185, 129, 0.1);
}

.gold-change.negative {
    color: var(--color-error);
    background: rgba(239, 68, 68, 0.1);
}

.gold-change.neutral {
    color: var(--color-gray-500);
    background: var(--color-gray-100);
}

.gold-card.featured .gold-change {
    background: rgba(255, 255, 255, 0.2);
}

.gold-card.featured .gold-change.positive {
    color: #86EFAC;
}

/* International Gold Price Bar */
.gold-international {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    padding: var(--space-4) var(--space-6);
    background: linear-gradient(135deg, var(--color-gray-900) 0%, var(--color-black) 100%);
    border-radius: var(--radius-xl);
    color: var(--color-white);
}

.intl-gold-icon {
    font-size: var(--text-2xl);
}

.intl-gold-info {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.intl-label {
    font-size: var(--text-sm);
    color: var(--color-gray-400);
}

.intl-price {
    font-family: var(--font-english);
    font-size: var(--text-2xl);
    font-weight: 800;
    color: var(--color-gold);
}

.intl-gold-change {
    display: flex;
    align-items: center;
    gap: var(--space-1);
    font-family: var(--font-english);
    font-weight: 600;
    font-size: var(--text-sm);
    padding: var(--space-2) var(--space-3);
    border-radius: var(--radius-md);
}

.intl-gold-change svg {
    width: 14px;
    height: 14px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
}

.intl-gold-change.positive {
    background: rgba(16, 185, 129, 0.2);
    color: #86EFAC;
}

.intl-gold-change.negative {
    background: rgba(239, 68, 68, 0.2);
    color: #FCA5A5;
}

/* Gold Section Responsive */
@media (max-width: 992px) {
    .gold-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .gold-grid {
        grid-template-columns: 1fr;
    }

    .gold-header {
        flex-direction: column;
        gap: var(--space-3);
        text-align: center;
    }

    .gold-international {
        flex-direction: column;
        text-align: center;
    }

    .intl-gold-info {
        align-items: center;
    }

    .rates-tabs {
        flex-direction: column;
        width: 100%;
    }

    .rates-tab {
        justify-content: center;
    }
}

/* ========================================
   SPLASH SCREEN (Mobile WOW Effect)
   ======================================== */
.splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--color-teal-dark) 0%, var(--color-teal) 50%, var(--color-teal-dark) 100%);
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.splash-screen.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.splash-content {
    text-align: center;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    perspective: 1000px;
}

/* 3D Coin Container */
.coin-container {
    width: 140px;
    height: 140px;
    margin-bottom: var(--space-8);
    position: relative;
    transform-style: preserve-3d;
    filter: drop-shadow(0 10px 30px rgba(212, 175, 55, 0.4));
}

.coin {
    width: 100%;
    height: 100%;
    position: absolute;
    transform-style: preserve-3d;
    animation: coin-spin 4s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.coin-face {
    position: absolute;
    width: 140px;
    height: 140px;
    background: radial-gradient(circle at 30% 30%, var(--color-gold-light), var(--color-gold));
    border: 5px solid #FCD34D;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    font-weight: 800;
    color: #713F12;
    text-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
    box-shadow:
        inset 0 0 30px rgba(0, 0, 0, 0.2),
        0 0 20px rgba(212, 175, 55, 0.3);
    backface-visibility: hidden;
}

.coin-face.front {
    transform: translateZ(10px);
}

.coin-face.back {
    transform: rotateY(180deg) translateZ(10px);
    background: radial-gradient(circle at 30% 30%, var(--color-teal), var(--color-teal-dark));
    color: var(--color-gold);
    border-color: var(--color-teal-light);
}

.coin-face.right {
    transform: rotateY(90deg) translateZ(10px);
    background: radial-gradient(circle at 30% 30%, var(--color-white), var(--color-gray-200));
    color: var(--color-teal);
}

.coin-face.left {
    transform: rotateY(-90deg) translateZ(10px);
    background: radial-gradient(circle at 30% 30%, #E6BE8A, #B8860B);
    color: #fff;
}

/* Coin Thickness (Edge) */
.coin-face.top,
.coin-face.bottom {
    display: none;
    /* Simplified for performance */
}

/* Shadow */
.coin-shadow {
    position: absolute;
    bottom: -45px;
    left: 50%;
    transform: translateX(-50%) rotateX(60deg);
    width: 140px;
    height: 35px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 50%;
    filter: blur(10px);
    animation: shadow-pulse 4s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

/* Particles Background */
.particles-container {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    overflow: hidden;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--color-gold);
    border-radius: 50%;
    opacity: 0;
    box-shadow: 0 0 10px var(--color-gold);
    animation: particle-float 4s ease-in-out infinite;
}

.particle:nth-child(1) {
    left: 10%;
    animation-delay: 0s;
}

.particle:nth-child(2) {
    left: 25%;
    animation-delay: 0.5s;
}

.particle:nth-child(3) {
    left: 40%;
    animation-delay: 1s;
}

.particle:nth-child(4) {
    left: 55%;
    animation-delay: 1.5s;
}

.particle:nth-child(5) {
    left: 70%;
    animation-delay: 0.3s;
}

.particle:nth-child(6) {
    left: 85%;
    animation-delay: 0.8s;
}

.particle:nth-child(7) {
    left: 20%;
    animation-delay: 1.2s;
}

.particle:nth-child(8) {
    left: 90%;
    animation-delay: 0.2s;
}

@keyframes particle-float {
    0% {
        bottom: 0;
        opacity: 0;
        transform: translateX(0) scale(0);
    }

    20% {
        opacity: 1;
        transform: translateX(10px) scale(1);
    }

    80% {
        opacity: 1;
        transform: translateX(-10px) scale(1);
    }

    100% {
        bottom: 100%;
        opacity: 0;
        transform: translateX(0) scale(0);
    }
}

/* Loading Bar */
.loading-bar-container {
    width: 280px;
    height: 8px;
    background: rgba(26, 95, 95, 0.3);
    border-radius: 20px;
    overflow: hidden;
    margin-bottom: var(--space-2);
    position: relative;
    border: 1px solid rgba(212, 175, 55, 0.2);
}

.loading-bar {
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
            var(--color-gold-dark) 0%,
            var(--color-gold) 50%,
            var(--color-gold-light) 100%);
    border-radius: 20px;
    transform: translateX(-100%);
    animation: loading-progress 3.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    box-shadow:
        0 0 20px rgba(212, 175, 55, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    position: relative;
}

.loading-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.4), transparent);
    border-radius: 20px 20px 0 0;
}

.loading-percentage {
    display: block;
    text-align: center;
    color: var(--color-gold-light);
    font-size: 0.9rem;
    font-weight: 600;
    font-family: var(--font-english);
    margin-top: var(--space-3);
    letter-spacing: 2px;
}

/* Splash Text Container */
.splash-text-container {
    margin-bottom: var(--space-6);
    opacity: 0;
    transform: translateY(20px);
    animation: content-slide-up 0.8s ease-out 0.5s forwards;
}

.splash-title {
    font-family: var(--font-arabic);
    font-size: 2rem;
    font-weight: 800;
    color: var(--color-white);
    margin: 0 0 var(--space-2) 0;
    background: linear-gradient(to right, #C5A349, #FCD34D, #C5A349);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 2px 10px rgba(0, 0, 0, 0.3));
}

.splash-subtitle {
    color: var(--color-gray-200);
    font-size: 1.1rem;
    font-weight: 400;
    letter-spacing: 0.5px;
}

/* Animations */
@keyframes content-slide-up {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes coin-spin {
    0% {
        transform: rotateY(0deg);
    }

    100% {
        transform: rotateY(360deg);
    }
}

@keyframes shadow-pulse {

    0%,
    100% {
        transform: translateX(-50%) rotateX(60deg) scale(1);
        opacity: 0.4;
    }

    50% {
        transform: translateX(-50%) rotateX(60deg) scale(0.8);
        opacity: 0.2;
    }
}

@keyframes loading-progress {
    0% {
        transform: translateX(-100%);
    }

    100% {
        transform: translateX(0);
    }
}

/* ========================================
   COUNTER ANIMATION (Number Animation)
   ======================================== */
.animate-counter {
    display: inline-block;
    transition: all 0.3s ease;
}

.counter-highlight {
    animation: counter-pop 0.3s ease-out;
}

@keyframes counter-pop {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.15);
        color: var(--color-gold);
    }

    100% {
        transform: scale(1);
    }
}

/* ========================================
   HAPTIC FEEDBACK (Touch Feedback)
   ======================================== */
.btn-haptic {
    position: relative;
    overflow: hidden;
}

.btn-haptic::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.3s ease, height 0.3s ease;
}

.btn-haptic:active::after {
    width: 200%;
    height: 200%;
}

/* Ripple effect on tap */
.ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.4);
    transform: scale(0);
    animation: ripple-effect 0.6s ease-out;
    pointer-events: none;
}

@keyframes ripple-effect {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Value boxes get special attention */
.value-num {
    transition: all 0.3s ease;
}

.value-box:hover .value-num {
    transform: scale(1.1);
    color: var(--color-gold);
}

/* ========================================
   LOGO TEXT (Company Name)
   ======================================== */
.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.logo-title {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--color-teal);
    white-space: nowrap;
}

.logo-subtitle {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--color-gold);
    white-space: nowrap;
}

[data-theme="dark"] .logo-title {
    color: var(--color-gold);
}

[data-theme="dark"] .logo-subtitle {
    color: var(--color-gray-300);
}

@media (max-width: 768px) {
    .logo-title {
        font-size: 1rem;
    }

    .logo-subtitle {
        font-size: 0.7rem;
    }
}

/* ========================================
   CURRENCY CARDS ENHANCEMENTS
   ======================================== */
.rates-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-8);
}

.smart-card {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-xl);
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
    position: relative;
}

.smart-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: var(--color-gold);
}

@media (max-width: 768px) {
    .rates-cards {
        gap: var(--space-4);
        grid-template-columns: 1fr;
    }
}

/* ========================================
   WELCOME MODAL
   ======================================== */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    z-index: var(--z-modal);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--transition-normal), visibility var(--transition-normal);
}

.modal-backdrop.show {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: rgba(255, 255, 255, 0.95);
    padding: var(--space-8);
    border-radius: var(--radius-2xl);
    width: 90%;
    max-width: 450px;
    text-align: center;
    position: relative;
    box-shadow: var(--shadow-2xl);
    border: 1px solid rgba(255, 255, 255, 0.5);
    transform: scale(0.9) translateY(20px);
    opacity: 0;
    transition: transform var(--transition-normal), opacity var(--transition-normal);
}

.modal-backdrop.show .modal-content {
    transform: scale(1) translateY(0);
    opacity: 1;
}

[data-theme="dark"] .modal-content {
    background: rgba(22, 27, 34, 0.95);
    border-color: rgba(255, 255, 255, 0.1);
}

.modal-close {
    position: absolute;
    top: var(--space-4);
    right: var(--space-4);
    background: none;
    border: none;
    font-size: var(--text-2xl);
    color: var(--color-gray-400);
    cursor: pointer;
    line-height: 1;
    padding: var(--space-1);
    transition: color var(--transition-fast);
}

.modal-close:hover {
    color: var(--color-error);
}

.modal-content.modal-lg {
    max-width: 600px;
    padding: var(--space-8) var(--space-6);
}

.modal-header {
    margin-bottom: var(--space-6);
}

.welcome-label {
    display: block;
    font-size: var(--text-sm);
    color: var(--color-gray-500);
    margin-bottom: var(--space-2);
    font-weight: 500;
}

.modal-company-name {
    font-size: var(--text-2xl);
    font-weight: 800;
    color: var(--color-teal);
    margin: 0 0 var(--space-2) 0;
    line-height: 1.2;
}

[data-theme="dark"] .modal-company-name {
    color: var(--color-teal);
}

.modal-subtitle {
    font-size: var(--text-base);
    color: var(--color-gray-600);
    margin: 0;
}

.markets-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-4);
    margin-bottom: var(--space-8);
}

@media (max-width: 480px) {
    .markets-grid {
        grid-template-columns: 1fr;
    }
}

.market-card {
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: var(--radius-lg);
    padding: var(--space-4);
    position: relative;
    overflow: hidden;
}

[data-theme="dark"] .market-card {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.market-sanaa {
    border-top: 3px solid var(--color-teal);
}

.market-aden {
    border-top: 3px solid var(--color-gold);
}

.market-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-4);
}

.location-badge {
    font-weight: 700;
    font-size: var(--text-sm);
    color: var(--color-gray-800);
}

[data-theme="dark"] .location-badge {
    color: var(--color-gray-200);
}

.status-dot {
    width: 8px;
    height: 8px;
    background-color: var(--color-success);
    border-radius: 50%;
    display: block;
}

.status-dot.pulse {
    animation: pulse-green 2s infinite;
}

.currency-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-2) 0;
}

.currency-info {
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.flag-icon {
    font-size: 1.2rem;
}

.currency-name {
    font-size: var(--text-xs);
    color: var(--color-gray-600);
    font-weight: 500;
}

.currency-rate {
    display: flex;
    align-items: baseline;
    gap: 2px;
}

.rate-num {
    font-family: var(--font-english);
    font-weight: 700;
    font-size: var(--text-lg);
    color: var(--color-gray-900);
}

[data-theme="dark"] .rate-num {
    color: var(--color-white);
}

.currency-symbol {
    font-size: 0.7rem;
    color: var(--color-gray-500);
}

.currency-divider {
    height: 1px;
    background: rgba(0, 0, 0, 0.05);
    margin: var(--space-2) 0;
}

[data-theme="dark"] .currency-divider {
    background: rgba(255, 255, 255, 0.1);
}

.modal-actions {
    margin-top: var(--space-6);
    display: flex;
    justify-content: center;
}

.modal-actions .btn {
    width: auto;
    min-width: 200px;
    padding: var(--space-3) var(--space-6);
    font-size: var(--text-sm);
}

/* ========================================
   FOOTER BOTTOM ENHANCEMENTS
   ======================================== */
.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--space-6);
    margin-top: var(--space-8);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    flex-wrap: wrap;
    gap: var(--space-4);
}

.footer-info {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

.copyright {
    color: var(--color-gray-400);
    font-size: var(--text-sm);
}

.developer-wrapper {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-size: var(--text-xs);
    color: var(--color-gray-500);
}

.dev-label {
    opacity: 0.8;
}

.developer-credit {
    color: var(--color-gold);
    text-decoration: none;
    font-weight: 600;
    transition: color var(--transition-fast);
    position: relative;
    padding-bottom: 2px;
}

.developer-credit::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    /* RTL */
    width: 0;
    height: 1px;
    background: var(--color-gold);
    transition: width var(--transition-base);
}

.developer-credit:hover {
    color: var(--color-gold-light);
}

.developer-credit:hover::after {
    width: 100%;
}

.footer-badges {
    display: flex;
    align-items: center;
}

.footer-badges .badge {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: var(--space-2) var(--space-3);
    border-radius: var(--radius-full);
    font-size: var(--text-xs);
    color: var(--color-gray-400);
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

@media (max-width: 768px) {
    .footer-bottom {
        flex-direction: column;
        text-align: center;
        gap: var(--space-6);
    }

    .footer-info {
        align-items: center;
    }

    .developer-wrapper {
        justify-content: center;
        flex-direction: column;
        gap: 2px;
    }
}