/* style.css */
@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;600;700;800&display=swap');

:root {
    --bg-color: #1B0B12;
    --primary: #E6005C;
    --secondary: #F2A3C0;
    --text-light: #F7F5F6;
    --text-muted: #B9B2B6;
    --glass: rgba(255, 255, 255, 0.03);
    --glass-hover: rgba(255, 255, 255, 0.08);
    --border: rgba(242, 163, 192, 0.15);
    --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.3);
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Cairo', sans-serif;
}

html {
    scroll-behavior: smooth;
    direction: rtl;
}

body {
    background-color: var(--bg-color);
    color: var(--text-light);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Background Abstract Shapes */
.bg-blobs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.15;
    animation: move 20s infinite alternate;
}

.blob-1 {
    width: 400px;
    height: 400px;
    background: var(--primary);
    top: -100px;
    left: -100px;
}

.blob-2 {
    width: 300px;
    height: 300px;
    background: var(--secondary);
    bottom: -50px;
    right: -50px;
    animation-delay: -5s;
}

@keyframes move {
    from {
        transform: translate(0, 0) scale(1);
    }

    to {
        transform: translate(50px, 50px) scale(1.1);
    }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Typography */
h1,
h2,
h3 {
    font-weight: 800;
    letter-spacing: -0.5px;
}

h2 {
    font-size: 2.5rem;
}

p {
    color: var(--text-muted);
    font-weight: 300;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 36px;
    border-radius: 100px;
    text-decoration: none;
    font-weight: 700;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-size: 1rem;
    gap: 10px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), #b30047);
    color: white;
    box-shadow: 0 4px 15px rgba(230, 0, 92, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(230, 0, 92, 0.5);
}

.btn-outline {
    border: 2px solid var(--border);
    color: var(--text-light);
    background: transparent;
}

.btn-outline:hover {
    background: var(--glass-hover);
    border-color: var(--secondary);
    transform: translateY(-3px);
}

/* Header */
header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(27, 11, 18, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1000;
    border-bottom: 1px solid var(--border);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.6rem;
    font-weight: 900;
    color: var(--text-light);
    text-decoration: none;
}

.logo span {
    color: var(--primary);
}

.logo img {
    height: 32px;
}

.nav-links {
    display: flex;
    gap: 32px;
    list-style: none;
}

.nav-links a {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    position: relative;
    transition: var(--transition);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    right: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--primary);
}

.nav-links a:hover::after {
    width: 100%;
}

/* Mobile Toggle */
.menu-btn {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
}

.menu-btn span {
    width: 30px;
    height: 2px;
    background: white;
    transition: var(--transition);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 80px;
    text-align: center;
    position: relative;
}

.hero-content {
    max-width: 850px;
    margin: 0 auto;
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    line-height: 1.1;
    margin-bottom: 24px;
    background: linear-gradient(to bottom, #fff 40%, var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    font-size: clamp(1.1rem, 2vw, 1.4rem);
    margin-bottom: 48px;
}

.hero-btns {
    display: flex;
    gap: 20px;
    justify-content: center;
}

/* Section Common */
section {
    padding: 100px 0;
}

.section-tag {
    color: var(--primary);
    text-transform: uppercase;
    font-weight: 800;
    font-size: 0.9rem;
    letter-spacing: 2px;
    margin-bottom: 12px;
    display: block;
}

.section-title {
    text-align: center;
    margin-bottom: 64px;
}

/* Grid Layouts */
.grid-3 {
    display: grid;
    gap: 32px;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.grid-4 {
    display: grid;
    gap: 24px;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

/* Cards */
.card {
    background: var(--glass);
    border: 1px solid var(--border);
    padding: 48px;
    border-radius: 40px;
    transition: var(--transition);
    height: 100%;
}

.card:hover {
    transform: translateY(-12px);
    background: var(--glass-hover);
    border-color: var(--secondary);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.card-icon {
    width: 64px;
    height: 64px;
    background: rgba(230, 0, 92, 0.1);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 32px;
    color: var(--primary);
}

.card-icon svg {
    width: 32px;
    height: 32px;
}

.card h3 {
    font-size: 1.5rem;
    margin-bottom: 16px;
}

/* Package Cards */
.package-card {
    padding: 48px 40px;
    text-align: center;
    position: relative;
    display: flex;
    flex-direction: column;
}

.package-card.featured {
    background: linear-gradient(180deg, rgba(230, 0, 92, 0.05) 0%, rgba(27, 11, 18, 0.5) 100%);
    border-color: var(--primary);
    transform: scale(1.05);
}

.package-card.featured:hover {
    transform: scale(1.05) translateY(-10px);
}

.badge {
    position: absolute;
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: white;
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 700;
}

.price {
    font-size: 3rem;
    font-weight: 900;
    margin: 24px 0;
    color: white;
}

.price span {
    font-size: 1rem;
    color: var(--text-muted);
}

.features-list {
    list-style: none;
    margin-bottom: 40px;
    flex-grow: 1;
}

.features-list li {
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
}

.features-list li svg {
    color: var(--primary);
    width: 18px;
}

/* Coverage Chips */
.chips-container {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: center;
    margin-top: 40px;
}

.chip {
    padding: 12px 32px;
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: 100px;
    font-weight: 700;
    color: var(--secondary);
    transition: var(--transition);
}

.chip:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* About Section Specific */
.about-flex {
    display: flex;
    gap: 64px;
    align-items: center;
}

.about-text {
    flex: 1;
    text-align: justify;
}

.about-text p {
    font-size: 1.1rem;
    margin-bottom: 24px;
    line-height: 1.8;
}

/* FAQ Accordion */
.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    margin-bottom: 16px;
    border-radius: 24px;
    background: var(--glass);
    border: 1px solid var(--border);
    overflow: hidden;
    transition: var(--transition);
}

.faq-header {
    padding: 24px 32px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 700;
    font-size: 1.1rem;
}

.faq-icon {
    width: 24px;
    height: 24px;
    position: relative;
    transition: var(--transition);
}

.faq-icon::before,
.faq-icon::after {
    content: '';
    position: absolute;
    background: white;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.faq-icon::before {
    width: 2px;
    height: 14px;
}

.faq-icon::after {
    width: 14px;
    height: 2px;
}

.faq-item.active .faq-icon {
    transform: rotate(135deg);
}

.faq-body {
    padding: 0 32px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
}

.faq-item.active .faq-body {
    padding-bottom: 24px;
    max-height: 300px;
}

/* Contact Section */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 64px;
}

.contact-info h3 {
    margin-bottom: 24px;
}

.contact-method {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 32px;
    background: var(--glass);
    padding: 24px;
    border-radius: 24px;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: var(--primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

/* Form Styles */
.form-card {
    background: var(--glass);
    padding: 48px;
    border-radius: 40px;
    border: 1px solid var(--border);
}

.form-group {
    margin-bottom: 24px;
}

label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--text-muted);
}

input,
select,
textarea {
    width: 100%;
    padding: 16px 24px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border);
    border-radius: 16px;
    color: white;
    font-size: 1rem;
    transition: var(--transition);
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 4px rgba(230, 0, 92, 0.1);
}

/* Toast */
.toast-container {
    position: fixed;
    bottom: 40px;
    right: 40px;
    z-index: 2000;
}

.toast {
    background: #2ecc71;
    color: white;
    padding: 16px 32px;
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    margin-top: 10px;
    animation: slideIn 0.4s forwards;
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Footer */
footer {
    padding: 80px 0 40px;
    border-top: 1px solid var(--border);
    background: #11070b;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.social-links {
    display: flex;
    gap: 20px;
}

.social-links a {
    color: var(--text-muted);
    transition: var(--transition);
}

.social-links a:hover {
    color: var(--primary);
}

.copyright {
    text-align: center;
    padding-top: 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: #555;
    font-size: 0.9rem;
}

/* Dashboard Table System */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 48px;
}

.search-wrapper {
    position: relative;
    width: 400px;
}

.search-wrapper input {
    padding-right: 48px;
}

.search-wrapper svg {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.table-glass {
    background: var(--glass);
    border-radius: 32px;
    border: 1px solid var(--border);
    overflow: hidden;
}

table {
    width: 100%;
    border-collapse: collapse;
    text-align: right;
}

th {
    background: rgba(255, 255, 255, 0.02);
    padding: 24px;
    color: var(--secondary);
    font-weight: 800;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

td {
    padding: 20px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

.status-badge {
    padding: 4px 12px;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 700;
}

.badge-ems {
    background: rgba(230, 0, 92, 0.15);
    color: var(--primary);
}

/* Mobile Responsiveness */
@media (max-width: 992px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .about-flex {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .nav-links.active {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background: var(--bg-color);
        padding: 40px;
        border-bottom: 2px solid var(--primary);
    }

    .menu-btn {
        display: flex;
    }

    .hero h1 {
        font-size: 2.8rem;
    }

    .hero-btns {
        flex-direction: column;
    }

    .footer-content {
        flex-direction: column;
        gap: 32px;
    }

    .card {
        padding: 32px;
    }

    .search-wrapper {
        width: 100%;
    }
}

/* System Toggle Styles */
.toggle-btn {
    padding: 12px 36px;
    border-radius: 50px;
    background: transparent;
    color: var(--text-muted);
    font-weight: 700;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.toggle-btn.active {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 15px rgba(230, 0, 92, 0.3);
}

.package-grid {
    display: none;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.package-grid.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.grid-2 {
    display: grid;
    gap: 32px;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

/* 3D Stack Slider System */
.stack-scene {
    position: relative;
    width: 100%;
    max-width: 900px;
    height: 600px;
    margin: 40px auto;
    perspective: 1000px;
    overflow: visible;
    /* Allow overflowing for effects */
}

/* Ensure stack-scene works with package-grid toggle */
.package-grid.stack-scene {
    /* Keep package-grid properties but ensure height */
}

.stack-list {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    transform-style: preserve-3d;
}

.stack-card {
    position: absolute;
    width: 100%;
    max-width: 380px;
    height: auto;
    min-height: 550px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.01));
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 30px;
    padding: 40px 30px;
    text-align: center;
    transition: all 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
    cursor: pointer;
    user-select: none;
    transform-origin: center center;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* Featured Card Style Override */
.stack-card.featured {
    border-color: var(--primary);
    background: linear-gradient(135deg, rgba(230, 0, 92, 0.1), rgba(20, 10, 15, 0.8));
}

/* States */
.stack-card.active {
    z-index: 10;
    transform: translateX(0) scale(1);
    opacity: 1;
    filter: blur(0);
    pointer-events: auto;
    box-shadow: 0 25px 50px rgba(230, 0, 92, 0.15);
}

.stack-card.next {
    z-index: 5;
    transform: translateX(60%) scale(0.85) rotateY(-15deg);
    opacity: 0.6;
    filter: blur(4px);
    pointer-events: auto;
    /* Allow clicking to bring to front */
}

.stack-card.prev {
    z-index: 5;
    transform: translateX(-60%) scale(0.85) rotateY(15deg);
    opacity: 0.6;
    filter: blur(4px);
    pointer-events: auto;
}

.stack-card.next-2 {
    z-index: 2;
    transform: translateX(90%) scale(0.7) rotateY(-25deg);
    opacity: 0.3;
    filter: blur(8px);
    pointer-events: none;
}

.stack-card.prev-2 {
    z-index: 2;
    transform: translateX(-90%) scale(0.7) rotateY(25deg);
    opacity: 0.3;
    filter: blur(8px);
    pointer-events: none;
}

.stack-card.hidden {
    z-index: 0;
    opacity: 0;
    transform: scale(0.5);
    pointer-events: none;
    display: none;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .stack-scene {
        height: 550px;
        perspective: 600px;
    }

    .stack-card {
        max-width: 280px;
        min-height: 480px;
        padding: 30px 20px;
    }

    .stack-card.next {
        transform: translateX(18%) scale(0.8) rotateY(-5deg);
        /* Tighter stack on mobile */
        opacity: 0.8;
    }

    .stack-card.prev {
        transform: translateX(-18%) scale(0.8) rotateY(5deg);
        opacity: 0.8;
    }

    .stack-card h3 {
        font-size: 1.3rem;
    }

    .stack-card .price {
        font-size: 2.5rem;
    }
}

/* Navigation Controls */
.stack-controls {
    display: flex;
    justify-content: center;
    gap: 30px;
    /* More space */
    margin-top: 10px;
    position: relative;
    z-index: 20;
    /* Ensure clickable */
}

.control-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    font-size: 1.5rem;
}

.control-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    transform: scale(1.1);
    box-shadow: 0 0 20px rgba(230, 0, 92, 0.4);
}