/* 🎨 Ard Al-Dyafa Coming Soon - Premium Stylesheet */

/* Design Tokens & Root Custom Properties */
:root {
    --gold-primary: hsl(43, 74%, 49%);
    --gold-secondary: hsl(43, 85%, 65%);
    --gold-light: hsl(43, 60%, 80%);
    --dark-bg: hsl(222, 47%, 7%);
    --dark-card: hsla(222, 47%, 12%, 0.65);
    --dark-border: hsla(43, 74%, 49%, 0.15);
    --dark-border-hover: hsla(43, 74%, 49%, 0.4);
    --text-primary: hsl(210, 40%, 98%);
    --text-secondary: hsl(215, 20%, 75%);
    --text-muted: hsl(215, 15%, 55%);
    --glow-color: rgba(212, 175, 55, 0.15);
    --font-ar: 'Cairo', sans-serif;
    --font-en: 'Montserrat', sans-serif;
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    min-height: 100vh;
    background-color: var(--dark-bg);
    color: var(--text-primary);
    font-family: var(--font-ar);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--dark-bg);
}
::-webkit-scrollbar-thumb {
    background: var(--gold-primary);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--gold-secondary);
}

/* Background Ambient Lighting */
.bg-glow {
    position: fixed;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.4;
    z-index: -1;
    pointer-events: none;
}

.bg-glow-1 {
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, var(--gold-primary) 0%, transparent 70%);
    top: -20%;
    right: -10%;
    animation: floatingGlow 15s infinite ease-in-out alternate;
}

.bg-glow-2 {
    width: 40vw;
    height: 40vw;
    background: radial-gradient(circle, hsl(210, 100%, 25%) 0%, transparent 75%);
    bottom: -10%;
    left: -10%;
    animation: floatingGlow 20s infinite ease-in-out alternate-reverse;
}

.bg-glow-3 {
    width: 30vw;
    height: 30vw;
    background: radial-gradient(circle, var(--gold-secondary) 0%, transparent 60%);
    top: 40%;
    left: 30%;
    animation: pulseGlow 10s infinite ease-in-out;
}

@keyframes floatingGlow {
    0% {
        transform: translate(0, 0) scale(1);
    }
    100% {
        transform: translate(-5%, 8%) scale(1.1);
    }
}

@keyframes pulseGlow {
    0%, 100% {
        opacity: 0.25;
        transform: scale(0.9);
    }
    50% {
        opacity: 0.45;
        transform: scale(1.1);
    }
}

/* Layout Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    z-index: 10;
}

/* Header Section */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 2rem;
    border-bottom: 1px solid hsla(215, 20%, 20%, 0.3);
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo-svg {
    width: 55px;
    height: 55px;
    filter: drop-shadow(0 0 8px rgba(212, 175, 55, 0.4));
    animation: spinSlow 30s linear infinite;
}

@keyframes spinSlow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-title {
    font-size: 1.6rem;
    font-weight: 900;
    color: var(--text-primary);
    letter-spacing: 0.5px;
    line-height: 1.2;
}

.logo-subtitle {
    font-family: var(--font-en);
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--gold-primary);
    letter-spacing: 3px;
    margin-top: 2px;
}

.btn-lang {
    background: transparent;
    border: 1px solid var(--dark-border);
    color: var(--text-primary);
    padding: 0.5rem 1.2rem;
    border-radius: 50px;
    cursor: pointer;
    font-family: var(--font-en);
    font-size: 0.85rem;
    font-weight: 600;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.btn-lang::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(212, 175, 55, 0.1), transparent);
    transform: translateX(-100%);
    transition: var(--transition-smooth);
}

.btn-lang:hover {
    border-color: var(--gold-primary);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.2);
    transform: translateY(-2px);
}

.btn-lang:hover::before {
    transform: translateX(100%);
}

/* Main Content Area */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 4rem 0;
    text-align: center;
}

/* Hero Section */
.hero-section {
    max-width: 800px;
    margin-bottom: 3.5rem;
}

.badge {
    background: hsla(43, 74%, 49%, 0.1);
    border: 1px solid var(--dark-border);
    color: var(--gold-secondary);
    padding: 0.4rem 1.2rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
    display: inline-block;
    margin-bottom: 1.5rem;
    backdrop-filter: blur(10px);
    box-shadow: inset 0 0 8px rgba(212, 175, 55, 0.1);
}

.main-heading {
    font-size: clamp(2rem, 5vw, 3.8rem);
    font-weight: 900;
    line-height: 1.25;
    margin-bottom: 1.5rem;
    letter-spacing: -0.5px;
}

.main-heading .highlight {
    background: linear-gradient(135deg, var(--gold-primary) 30%, var(--gold-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 40px rgba(212, 175, 55, 0.1);
}

.sub-heading {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--text-secondary);
    max-width: 680px;
    margin: 0 auto;
    font-weight: 300;
}

/* Countdown Panel */
.timer-section {
    margin-bottom: 4rem;
    width: 100%;
    max-width: 650px;
}

.countdown-card {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 24px;
    padding: 2rem;
    display: grid;
    grid-template-cols: repeat(4, 1fr);
    gap: 1.5rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3),
                inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.countdown-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.countdown-item:not(:last-child)::after {
    content: ':';
    position: absolute;
    left: -0.75rem;
    top: 20%;
    font-size: 2rem;
    color: var(--gold-primary);
    opacity: 0.5;
}

/* Adjust divider for RTL */
html[dir="rtl"] .countdown-item:not(:last-child)::after {
    left: auto;
    right: -0.75rem;
}

.time-num {
    font-family: var(--font-en);
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
    background: linear-gradient(180deg, var(--text-primary) 50%, var(--text-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.time-label {
    font-size: 0.85rem;
    color: var(--gold-secondary);
    margin-top: 0.5rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* Subscribe Section */
.subscribe-section {
    width: 100%;
    max-width: 580px;
    margin-bottom: 4rem;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.section-desc {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 1.75rem;
}

.subscribe-form {
    width: 100%;
    position: relative;
}

.input-group {
    display: flex;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--dark-border);
    border-radius: 50px;
    padding: 0.4rem;
    transition: var(--transition-smooth);
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
}

.input-group:focus-within {
    border-color: var(--gold-primary);
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.15),
                inset 0 2px 4px rgba(0,0,0,0.2);
    background: rgba(255, 255, 255, 0.05);
}

.subscribe-form input[type="email"] {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-primary);
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    font-family: inherit;
}

.subscribe-form input[type="email"]::placeholder {
    color: var(--text-muted);
}

.btn-submit {
    background: linear-gradient(135deg, var(--gold-primary) 0%, var(--gold-secondary) 100%);
    border: none;
    outline: none;
    color: hsl(222, 47%, 7%);
    font-weight: 700;
    font-size: 0.95rem;
    padding: 0.8rem 1.8rem;
    border-radius: 50px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.3);
    transition: var(--transition-smooth);
}

.btn-icon {
    width: 16px;
    height: 16px;
    transition: var(--transition-smooth);
}

/* Arrow direction for RTL and LTR */
html[dir="rtl"] .btn-icon {
    transform: rotate(180deg);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.5);
    background: linear-gradient(135deg, var(--gold-secondary) 0%, var(--gold-light) 100%);
}

.btn-submit:hover .btn-icon {
    transform: translateX(-4px) rotate(180deg);
}

html[dir="ltr"] .btn-submit:hover .btn-icon {
    transform: translateX(4px) rotate(0deg);
}

.error-msg {
    color: hsl(0, 85%, 65%);
    font-size: 0.85rem;
    display: block;
    margin-top: 0.6rem;
    opacity: 0;
    transform: translateY(-5px);
    transition: var(--transition-smooth);
    pointer-events: none;
}

.error-msg.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Features Grid */
.features-section {
    width: 100%;
    margin-top: 2rem;
}

.features-grid {
    display: grid;
    grid-template-cols: repeat(3, 1fr);
    gap: 2rem;
    width: 100%;
}

.feature-card {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 20px;
    padding: 2.2rem 1.8rem;
    backdrop-filter: blur(12px);
    transition: var(--transition-smooth);
}

.feature-card:hover {
    transform: translateY(-8px);
    border-color: var(--dark-border-hover);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4),
                inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.feature-icon {
    font-size: 2.2rem;
    margin-bottom: 1.2rem;
    display: inline-block;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.3));
}

.feature-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 0.6rem;
    color: var(--text-primary);
}

.feature-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

html[dir="rtl"] .toast-container {
    right: auto;
    left: 2rem;
}

.toast {
    background: var(--dark-card);
    border-left: 4px solid var(--gold-primary);
    color: var(--text-primary);
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    gap: 1rem;
    backdrop-filter: blur(10px);
    animation: toastIn 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
    transition: var(--transition-smooth);
}

html[dir="rtl"] .toast {
    border-left: none;
    border-right: 4px solid var(--gold-primary);
    animation: toastInRtl 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateX(100%) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

@keyframes toastInRtl {
    from {
        opacity: 0;
        transform: translateX(-100%) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

.toast.fade-out {
    opacity: 0;
    transform: scale(0.85);
}

.toast-icon {
    font-size: 1.2rem;
}

.toast-message {
    font-size: 0.9rem;
    font-weight: 600;
}

/* Footer Section */
.footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    padding-top: 2rem;
    border-top: 1px solid hsla(215, 20%, 20%, 0.3);
}

.social-links {
    display: flex;
    gap: 1.25rem;
}

.social-link {
    color: var(--text-muted);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--dark-border);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: var(--transition-smooth);
}

.social-link svg {
    width: 18px;
    height: 18px;
}

.social-link:hover {
    color: var(--gold-secondary);
    background: hsla(43, 74%, 49%, 0.08);
    border-color: var(--gold-primary);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 5px 15px rgba(212, 175, 55, 0.2);
}

.copyright {
    font-size: 0.8rem;
    color: var(--text-muted);
    text-align: center;
}

/* Responsive Breakpoints */
@media (max-width: 992px) {
    .features-grid {
        grid-template-cols: repeat(2, 1fr);
        gap: 1.5rem;
    }
    .main-content {
        padding: 3rem 0;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 1.5rem;
    }
    .header {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }
    .features-grid {
        grid-template-cols: 1fr;
        gap: 1.25rem;
    }
    .countdown-card {
        padding: 1.5rem 1rem;
        gap: 0.75rem;
    }
    .countdown-item:not(:last-child)::after {
        display: none;
    }
    .input-group {
        flex-direction: column;
        border-radius: 20px;
        padding: 0.5rem;
        background: transparent;
        border: none;
        box-shadow: none;
        gap: 0.75rem;
    }
    .input-group input[type="email"] {
        background: rgba(255, 255, 255, 0.03);
        border: 1px solid var(--dark-border);
        border-radius: 50px;
        text-align: center;
        width: 100%;
    }
    .btn-submit {
        width: 100%;
        justify-content: center;
    }
}
