/* ==========================================================
   دكانك — نظام التصميم
   هوية بصرية مستوحاة من "دفتر الحسابات" و "بطاقة السعر المعلّقة"
   الألوان: أخضر مظلم (كالسنداين/المظلة) + كرافت فاتح + أحمر الختم + ذهبي الخيط
   ========================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@500;700;800&family=IBM+Plex+Sans+Arabic:wght@400;500;600&family=IBM+Plex+Mono:wght@500;600&display=swap');

:root {
    --ink: #14231C;
    --ink-2: #1C2F26;
    --ink-3: #223B2F;
    --paper: #F7F3E9;
    --sage: #9FB3A6;
    --stamp: #E4572E;
    --stamp-dark: #C4451F;
    --gold: #D4A73D;
    --line: rgba(247, 243, 233, 0.14);

    --font-display: 'Cairo', sans-serif;
    --font-body: 'IBM Plex Sans Arabic', sans-serif;
    --font-mono: 'IBM Plex Mono', monospace;

    --radius: 14px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    background: var(--ink);
    color: var(--paper);
    font-family: var(--font-body);
    line-height: 1.7;
    direction: rtl;
    overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }

.container {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 24px;
}

:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 3px;
}
.account-avatar{
    display:flex;
    align-items:center;
    justify-content:center;
    width:42px;
    height:42px;
    text-decoration:none;
}

.account-avatar img{
    width:42px;
    height:42px;
    border-radius:50%;
    object-fit:cover;
    border:2px solid rgba(255,255,255,.15);
    transition:.2s;
}

.account-avatar img:hover{
    transform:scale(1.08);
}

.avatar-letter{
    width:42px;
    height:42px;
    border-radius:50%;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#E4572E;
    color:#fff;
    font-weight:700;
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ---------- خط تقسيم على شكل ثقوب فاتورة ---------- */
.perforation {
    height: 1px;
    background-image: radial-gradient(circle, var(--ink) 2px, transparent 2.5px);
    background-size: 14px 1px;
    background-position: center;
    position: relative;
}
.perforation::before {
    content: '';
    position: absolute;
    inset: 0;
    border-top: 1px dashed var(--line);
}

/* ================= الهيدر ================= */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(20, 35, 28, 0.88);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--line);
}

.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
}

.logo {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.5rem;
    color: var(--paper);
    display: flex;
    align-items: center;
    gap: 8px;
}
.logo span { color: var(--stamp); }

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
    font-weight: 600;
}
.nav-links a {
    color: var(--sage);
    transition: color .2s;
    position: relative;
}
.nav-links a:hover, .nav-links a.active { color: var(--paper); }
.nav-links a.active::after {
    content: '';
    position: absolute;
    right: 0; left: 0; bottom: -18px;
    height: 2px;
    background: var(--stamp);
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 26px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.95rem;
    transition: transform .18s ease, box-shadow .18s ease;
}
.btn-stamp {
    background: var(--stamp);
    color: var(--paper);
    box-shadow: 0 4px 0 var(--stamp-dark);
}
.btn-stamp:hover { transform: translateY(-2px); box-shadow: 0 6px 0 var(--stamp-dark); }
.btn-ghost {
    border: 1.5px solid var(--line);
    color: var(--paper);
}
.btn-ghost:hover { border-color: var(--gold); }
.btn-block { width: 100%; justify-content: center; }

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 6px;
}
.hamburger span { width: 24px; height: 2px; background: var(--paper); border-radius: 2px; }

/* ================= الهيرو ================= */
.hero {
    padding: 100px 0 70px;
    position: relative;
}
.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 48px;
    align-items: center;
}
.eyebrow {
    font-family: var(--font-mono);
    color: var(--gold);
    font-size: 0.85rem;
    letter-spacing: 1px;
    margin-bottom: 18px;
    display: inline-block;
}
.hero h1 {
    font-family: var(--font-display);
    font-size: clamp(2.1rem, 4.5vw, 3.4rem);
    font-weight: 800;
    line-height: 1.25;
    margin-bottom: 20px;
}
.hero h1 em {
    font-style: normal;
    color: var(--stamp);
}
.hero p.lead {
    color: var(--sage);
    font-size: 1.1rem;
    max-width: 480px;
    margin-bottom: 32px;
}
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 36px; }

.hero-trust {
    display: flex;
    gap: 28px;
    font-family: var(--font-mono);
    color: var(--sage);
    font-size: 0.85rem;
}
.hero-trust strong { color: var(--paper); font-size: 1.1rem; display: block; }

/* ----- بطاقة السعر المعلّقة (العنصر التوقيعي) ----- */
.hero-visual {
    position: relative;
    display: flex;
    justify-content: center;
    padding-top: 40px;
}
.tag-string {
    position: absolute;
    top: -30px;
    right: 50%;
    width: 1px;
    height: 60px;
    background: var(--line);
}
.price-tag {
    background: var(--paper);
    color: var(--ink);
    width: 260px;
    padding: 28px 26px 32px;
    border-radius: 8px;
    position: relative;
    transform: rotate(-4deg);
    animation: swing 6s ease-in-out infinite;
    transform-origin: top center;
    box-shadow: 0 20px 40px rgba(0,0,0,0.35);
}
.price-tag::before {
    content: '';
    position: absolute;
    top: 14px; right: 50%;
    width: 14px; height: 14px;
    background: var(--ink);
    border-radius: 50%;
    box-shadow: 0 0 0 3px var(--paper) inset;
}
.price-tag .tag-label {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--stamp-dark);
    font-weight: 600;
    display: block;
    margin-top: 10px;
}
.price-tag .tag-store {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.2rem;
    margin: 6px 0 18px;
}
.price-tag .tag-price {
    font-family: var(--font-mono);
    font-size: 2.4rem;
    font-weight: 600;
    line-height: 1;
}
.price-tag .tag-price sup { font-size: 1rem; }
.price-tag .tag-period { color: #6b7d72; font-size: 0.85rem; }
.price-tag .tag-cut {
    position: absolute;
    bottom: -10px; left: 20px; right: 20px;
    height: 20px;
    background: repeating-linear-gradient(-45deg, var(--paper) 0 6px, transparent 6px 12px);
}

@keyframes swing {
    0%, 100% { transform: rotate(-4deg); }
    50% { transform: rotate(3deg); }
}

/* ================= شارات الثقة / اللوجوهات ================= */
.section { padding: 90px 0; }
.section-head { text-align: center; max-width: 620px; margin: 0 auto 56px; }
.section-head .eyebrow { display: block; text-align: center; }
.section-head h2 {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: clamp(1.7rem, 3vw, 2.4rem);
    margin-bottom: 14px;
}
.section-head p { color: var(--sage); font-size: 1.05rem; }

/* ================= المميزات ================= */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}
.feature-card {
    background: var(--ink-2);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 30px 26px;
    transition: border-color .2s, transform .2s;
}
.feature-card:hover { border-color: var(--gold); transform: translateY(-4px); }
.feature-icon {
    width: 46px; height: 46px;
    border-radius: 12px;
    background: var(--stamp);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.3rem;
    margin-bottom: 18px;
}
.feature-card h3 { font-family: var(--font-display); font-size: 1.15rem; margin-bottom: 10px; }
.feature-card p { color: var(--sage); font-size: 0.95rem; }

/* ================= خطوات البدء (تسلسل حقيقي) ================= */
.steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    position: relative;
}
.step { position: relative; padding-right: 8px; }
.step .step-num {
    font-family: var(--font-mono);
    color: var(--gold);
    font-size: 0.85rem;
    border: 1px solid var(--gold);
    width: 34px; height: 34px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 18px;
}
.step h3 { font-family: var(--font-display); font-size: 1.1rem; margin-bottom: 8px; }
.step p { color: var(--sage); font-size: 0.92rem; }

/* ================= بطاقات الباقات (تذاكر السوق) ================= */
.plans-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 26px;
    align-items: start;
}
.plan-ticket {
    background: var(--ink-2);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 34px 28px;
    position: relative;
    transition: transform .2s, border-color .2s;
}
.plan-ticket:nth-child(1) { transform: rotate(-1.2deg); }
.plan-ticket:nth-child(3) { transform: rotate(1.2deg); }
.plan-ticket:hover { transform: translateY(-6px) rotate(0deg); border-color: var(--gold); }
.plan-ticket::before {
    content: '';
    position: absolute;
    top: 30px; right: -9px;
    width: 18px; height: 18px;
    background: var(--ink);
    border-radius: 50%;
    border: 1px solid var(--line);
}
.plan-featured {
    border-color: var(--stamp);
    background: linear-gradient(160deg, var(--ink-3), var(--ink-2));
}
.plan-badge {
    position: absolute;
    top: -14px; left: 28px;
    background: var(--stamp);
    color: var(--paper);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 999px;
}
.plan-name { font-family: var(--font-display); font-weight: 800; font-size: 1.25rem; margin-bottom: 6px; }
.plan-price {
    font-family: var(--font-mono);
    font-size: 2.4rem;
    font-weight: 600;
    margin: 14px 0 4px;
}
.plan-price sup { font-size: 1rem; color: var(--sage); }
.plan-period { color: var(--sage); font-size: 0.85rem; margin-bottom: 24px; display: block; }
.plan-features { margin-bottom: 28px; }
.plan-features li {
    padding: 9px 0;
    border-bottom: 1px dashed var(--line);
    font-size: 0.92rem;
    color: var(--paper);
    display: flex;
    gap: 10px;
}
.plan-features li:last-child { border-bottom: none; }
.plan-features li::before { content: '✓'; color: var(--gold); font-weight: 700; }

/* ================= آراء العملاء ================= */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}
.testimonial {
    background: var(--ink-2);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 28px;
}
.testimonial p.quote { color: var(--paper); margin-bottom: 18px; font-size: 0.98rem; }
.testimonial .who { display: flex; align-items: center; gap: 12px; }
.avatar {
    width: 40px; height: 40px; border-radius: 50%;
    background: var(--stamp);
    font-family: var(--font-display);
    display: flex; align-items: center; justify-content: center;
    font-weight: 700;
}
.who strong { display: block; font-size: 0.9rem; }
.who span { color: var(--sage); font-size: 0.8rem; }

/* ================= CTA نهائي ================= */
.cta-band {
    background: var(--stamp);
    border-radius: 20px;
    padding: 60px 40px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.cta-band h2 { font-family: var(--font-display); font-size: clamp(1.6rem, 3vw, 2.2rem); margin-bottom: 14px; }
.cta-band p { color: rgba(20,35,28,0.75); margin-bottom: 28px; font-size: 1.05rem; }
.cta-band .btn-stamp { background: var(--ink); box-shadow: 0 4px 0 #000; color: var(--paper); }

/* ================= الفوتر ================= */
.site-footer { padding: 60px 0 30px; }
.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 32px;
    padding-bottom: 40px;
}
.footer-brand p { color: var(--sage); font-size: 0.9rem; margin-top: 14px; max-width: 260px; }
.footer-col h4 { font-family: var(--font-display); font-size: 0.95rem; margin-bottom: 16px; }
.footer-col li { margin-bottom: 10px; }
.footer-col a { color: var(--sage); font-size: 0.9rem; }
.footer-col a:hover { color: var(--paper); }
.footer-bottom {
    display: flex;
    justify-content: space-between;
    padding-top: 24px;
    border-top: 1px solid var(--line);
    color: var(--sage);
    font-size: 0.82rem;
    font-family: var(--font-mono);
}

/* ================= صفحات المصادقة (تسجيل / دخول) ================= */
.auth-wrap {
    min-height: calc(100vh - 74px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
}
.auth-card {
    background: var(--ink-2);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 40px 36px;
    width: 100%;
    max-width: 420px;
}
.auth-card h1 { font-family: var(--font-display); font-size: 1.6rem; margin-bottom: 6px; }
.auth-card p.sub { color: var(--sage); font-size: 0.92rem; margin-bottom: 28px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-size: 0.88rem; margin-bottom: 8px; color: var(--sage); }
.field input, .field select, .field textarea {
    width: 100%;
    padding: 13px 16px;
    background: var(--ink);
    border: 1px solid var(--line);
    border-radius: 10px;
    color: var(--paper);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: border-color .2s;
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--gold); outline: none; }
.field textarea { resize: vertical; min-height: 60px; }
.field-hint { font-size: 0.78rem; color: var(--sage); margin-top: 6px; }
.auth-alt { text-align: center; margin-top: 22px; font-size: 0.9rem; color: var(--sage); }
.auth-alt a { color: var(--gold); font-weight: 600; }

.alert {
    padding: 13px 16px;
    border-radius: 10px;
    font-size: 0.88rem;
    margin-bottom: 20px;
}
.alert-error { background: rgba(228, 87, 46, 0.15); border: 1px solid var(--stamp); color: #ffcbb8; }
.alert-success { background: rgba(212, 167, 61, 0.15); border: 1px solid var(--gold); color: #f4dfa4; }

/* ================= استجابة الموبايل ================= */
@media (max-width: 900px) {
    .hero-grid { grid-template-columns: 1fr; }
    .hero-visual { order: -1; }
    .features-grid, .steps, .plans-grid, .testimonials-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
    .nav-links { position: fixed; inset: 74px 0 0 0; background: var(--ink); flex-direction: column; padding: 30px; gap: 22px; transform: translateX(100%); transition: transform .25s ease; }
    .nav-links.open { transform: translateX(0); }
    .hamburger { display: flex; }
    .hero { padding: 60px 0 40px; }
    .footer-grid { grid-template-columns: 1fr; text-align: right; }
    .footer-bottom { flex-direction: column; gap: 10px; text-align: center; }
}
