:root {
    --bg-primary: #000000; /* Pure black iOS-like background */
    --accent: #10b981;
    --text-main: #ffffff;
    --text-muted: #a1a1aa;
    --glass-bg: rgba(24, 24, 27, 0.6);
    --glass-border: rgba(255, 255, 255, 0.08);
}

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

body {
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--bg-primary);
    color: var(--text-main);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    overscroll-behavior-y: none;
}

body[dir="rtl"] {
    font-family: 'Amiri', serif;
}

/* Ambient Modern Background */
.ambient-glow {
    position: fixed;
    top: -20%;
    left: 10%;
    width: 80vw;
    height: 80vw;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.15) 0%, transparent 60%);
    filter: blur(60px);
    z-index: 0;
    pointer-events: none;
    animation: drift 20s infinite alternate cubic-bezier(0.4, 0, 0.2, 1);
}
.ambient-glow.glow-2 {
    top: 40%;
    left: 40%;
    background: radial-gradient(circle, rgba(56, 189, 248, 0.08) 0%, transparent 60%);
    animation-delay: -5s;
}
@keyframes drift {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(-10%, 10%) scale(1.1); }
}

.screen {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    min-height: 100vh;
    z-index: 10;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease, transform 0.4s ease;
    padding: 15px;
    transform: scale(0.98);
}
.screen.active {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}
.screen.exit-left {
    transform: translateX(-30px);
    opacity: 0;
}

.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid var(--glass-border);
    border-radius: 28px;
    padding: 32px 24px;
    width: 100%;
    max-width: 440px;
    box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(255,255,255,0.05);
}

/* Modern Logo & Fallback */
.logo-container {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    margin: 0 auto 32px;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 20px 40px rgba(16, 185, 129, 0.15);
    background: linear-gradient(135deg, #1e293b, #0f172a);
    overflow: hidden;
    padding: 0;
}
#app-logo {
    width: 100%; height: 100%;
    object-fit: cover;
    border-radius: 50%;
    transform: scale(1.65) translateX(-4%); /* Heavy zoom to completely hide white borders and shift left */
}
.app-logo-fallback {
    width: 100%; height: 100%;
    border-radius: 50%;
    background: linear-gradient(135deg, #bbf7d0, #4ade80);
    display: flex; align-items: center; justify-content: center;
    color: #14532d;
    font-size: 64px;
    box-shadow: inset 0 2px 8px rgba(255,255,255,0.8);
}

.header-brand {
    display: flex; align-items: center; gap: 12px;
}
.header-brand h2 { font-weight: 600; font-size: 20px; letter-spacing: -0.5px; }

.header-logo-container {
    width: 36px; height: 36px;
    border-radius: 50%;
    overflow: hidden;
    display: flex; justify-content: center; align-items: center;
    background: #1e293b;
}
.header-logo { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; transform: scale(1.65) translateX(-4%); }
.header-logo-fallback {
    width: 100%; height: 100%;
    border-radius: 50%;
    background: linear-gradient(135deg, #bbf7d0, #4ade80);
    color: #14532d;
    display: flex; align-items: center; justify-content: center;
    font-size: 18px;
}

h1 { font-size: 28px; text-align: center; margin-bottom: 8px; font-weight: 700; letter-spacing: -0.5px; }
p { text-align: center; color: var(--text-muted); margin-bottom: 30px; line-height: 1.6; font-size: 15px;}
.subtitle {
    color: #34d399; /* Bright mint green matching the theme */
    font-weight: 500;
    font-size: 16px;
    letter-spacing: 0.2px;
}

/* Grid & Buttons */
.lang-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.btn, .lang-btn {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.06);
    color: white;
    padding: 16px;
    border-radius: 16px;
    font-size: 16px;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex; align-items: center; justify-content: center;
    font-weight: 500;
}
.btn:active, .lang-btn:active { transform: scale(0.96); opacity: 0.8; }
.lang-btn:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.15);
}

/* Animations */
.floating { animation: float 4s ease-in-out infinite; }
.floating-delay { animation: float 4s ease-in-out infinite; animation-delay: 2s; }
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-6px); }
    100% { transform: translateY(0px); }
}

.pulse { animation: pulse 2.5s infinite; }
.pulse-delay { animation: pulse 2.5s infinite; animation-delay: 1.25s; }
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); }
    100% { transform: scale(1); }
}

/* Main Screen Cards */
.main-panel { padding-top: 24px; }
.header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 32px; }
.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; }
.modal-header h3 { font-size: 20px; font-weight: 600; margin: 0; }

.icon-btn {
    background: rgba(255,255,255,0.05); border: 1px solid var(--glass-border); 
    color: var(--text-main); font-size: 16px; cursor: pointer; transition: 0.2s;
    width: 44px; height: 44px; border-radius: 50%; display: flex; justify-content: center; align-items: center;
    backdrop-filter: blur(10px);
}
.icon-btn:active { transform: scale(0.9); }
body[dir="rtl"] .icon-btn i.fa-arrow-left { transform: rotate(180deg); }

.cards { display: flex; flex-direction: column; gap: 16px; margin-top: 24px; }

.card {
    background: linear-gradient(180deg, rgba(255,255,255,0.06) 0%, rgba(255,255,255,0.02) 100%);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 20px;
    padding: 24px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}
.card::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(135deg, rgba(16,185,129,0.15) 0%, transparent 100%);
    opacity: 0; transition: 0.3s;
}
.card:active { transform: scale(0.97); }
.card:hover { border-color: rgba(16,185,129,0.4); box-shadow: 0 10px 30px rgba(16,185,129,0.1); }
.card:hover::before { opacity: 1; }

.card-icon { font-size: 32px; color: var(--accent); margin-bottom: 16px; }
.card h3 { font-size: 18px; margin-bottom: 6px; font-weight: 600; }
.card p { font-size: 14px; margin-bottom: 0; color: var(--text-muted); }

/* Modals */
.modal {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.8); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
    z-index: 100; display: flex; justify-content: center; align-items: flex-end; 
    opacity: 0; pointer-events: none; transition: 0.4s ease;
}
@media (min-width: 480px) { .modal { align-items: center; padding: 20px; } }
.modal.active { opacity: 1; pointer-events: auto; }

.modal-content {
    width: 100%; max-width: 450px;
    max-height: 90vh; overflow-y: auto;
    border-bottom-left-radius: 0; border-bottom-right-radius: 0;
    transform: translateY(100%); transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    background: #121214; 
    background: var(--glass-bg);
}
@media (min-width: 480px) { .modal-content { border-radius: 28px; transform: scale(0.95); }  }
.modal.active .modal-content { transform: translateY(0); }
@media (min-width: 480px) { .modal.active .modal-content { transform: scale(1); }  }

/* Segmented Tabs */
.tabs { display: flex; background: rgba(255,255,255,0.06); border-radius: 12px; padding: 4px; margin-bottom: 24px; position: relative; }
.tab-btn {
    flex: 1; background: transparent; border: none; color: var(--text-muted); font-size: 14px; font-weight: 600;
    padding: 12px; border-radius: 10px; cursor: pointer; transition: 0.3s; z-index: 2; position: relative;
}
.tab-btn.active { color: white; background: rgba(255,255,255,0.12); box-shadow: 0 4px 15px rgba(0,0,0,0.2); }

.tab-content { display: none; animation: fadeIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1); }
.tab-content.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* Info Grid */
.info-grid { display: flex; flex-direction: column; gap: 12px; }
.info-item {
    background: rgba(255,255,255,0.03); padding: 14px 18px; border-radius: 16px;
    display: flex; flex-direction: column; gap: 6px; border: 1px solid rgba(255,255,255,0.04);
}
.info-item span { font-size: 12px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; font-weight: 500;}
.info-item strong { font-size: 15px; color: white; user-select: text; font-weight: 500; word-break: break-all; transition: 0.2s; }
.info-item strong:active { color: var(--accent); opacity: 0.7; }

/* Alerts */
.note {
    margin-top: 16px; padding: 16px; border-radius: 16px; background: rgba(56, 189, 248, 0.08);
    border: 1px solid rgba(56, 189, 248, 0.15); color: #bae6fd;
    display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 1.5; text-align: left;
}
body[dir="rtl"] .note { text-align: right; }
.note i { font-size: 18px; margin-top: 2px; color: #38bdf8; }

/* Contact Buttons */
.contact-links { display: flex; flex-direction: column; gap: 14px; }
.contact-btn {
    display: flex; align-items: center; justify-content: center; gap: 14px;
    padding: 18px; border-radius: 18px; text-decoration: none; color: white;
    font-weight: 600; transition: 0.3s; font-size: 16px;
}
.contact-btn.email { background: linear-gradient(135deg, #ef4444, #b91c1c); box-shadow: 0 10px 20px rgba(239, 68, 68, 0.2); }
.contact-btn.whatsapp { background: linear-gradient(135deg, #22c55e, #15803d); box-shadow: 0 10px 20px rgba(34, 197, 94, 0.2); }
.contact-btn:active { transform: scale(0.96); box-shadow: none; }
.contact-btn i { font-size: 22px; }

::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 10px; }

/* Copy Feedback */
.toast {
    position: fixed; bottom: 30px; left: 50%; transform: translateX(-50%) translateY(100px);
    background: var(--accent); color: white; padding: 14px 28px; border-radius: 30px;
    font-weight: 600; box-shadow: 0 10px 30px rgba(16, 185, 129, 0.4); opacity: 0;
    transition: 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); z-index: 1000;
    font-size: 15px; white-space: nowrap;
}
.toast.show { transform: translateX(-50%) translateY(0); opacity: 1; }
