/* ============================================================
   جنة ليبيا — Luxury Perfume Design System
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500&family=Cairo:wght@300;400;500;600;700&display=swap');

:root {
    --primary:        #4F7C79;
    --primary-hover:  #3D6462;
    --secondary:      #C6A27E;
    --secondary-hover:#B5905D;
    --accent:         #C6A27E;
    --accent-hover:   #B5905D;
    --bg:             #F7F5F2;
    --bg-light:       #F7F5F2;
    --white:          #FFFFFF;
    --text-dark:      #1E2A2A;
    --text-body:      #4A5656;
    --text-muted:     #8A9696;
    --border:         rgba(30,42,42,.08);
    --shadow-sm:      0 2px 8px rgba(30,42,42,.04);
    --shadow-md:      0 8px 30px rgba(30,42,42,.07);
    --shadow-lg:      0 16px 50px rgba(30,42,42,.10);
    --shadow-glow:    0 8px 40px rgba(198,162,126,.15);
    --radius:         4px;
    --radius-lg:      8px;
    --transition:     all .4s cubic-bezier(.25,.46,.45,.94);
    --transition-slow: all .7s cubic-bezier(.25,.46,.45,.94);
    --font-heading:   'Playfair Display', 'Georgia', serif;
    --font-body:      'Cairo', 'Segoe UI', sans-serif;
}

/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; scroll-behavior: smooth; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--text-body);
    direction: rtl;
    line-height: 1.8;
    overflow-x: hidden;
}

::selection { background: var(--secondary); color: var(--white); }

a { color: inherit; text-decoration: none; transition: var(--transition); }
img { max-width: 100%; display: block; }
ul { list-style: none; }

/* ── Typography — Luxury ── */
h1, h2, h3, h4, h5 { font-family: var(--font-heading); color: var(--text-dark); line-height: 1.3; font-weight: 500; }
h1 { font-size: 2.8rem; letter-spacing: -.01em; }
h2 { font-size: 2.2rem; letter-spacing: -.01em; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.2rem; }
p  { color: var(--text-body); font-weight: 400; }

/* ── Container ── */
.container { width: 100%; max-width: 1340px; margin: 0 auto; padding: 0 2rem; }

/* ── Buttons — Luxury ── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    padding: .8rem 2.2rem;
    border-radius: 0;
    font-family: var(--font-body);
    font-size: .85rem;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
    cursor: pointer;
    border: 1.5px solid transparent;
    transition: var(--transition);
    white-space: nowrap;
}
.btn-primary {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}
.btn-primary:hover {
    background: transparent;
    color: var(--primary);
    border-color: var(--primary);
}
.btn-accent {
    background: var(--secondary);
    color: var(--white);
    border-color: var(--secondary);
}
.btn-accent:hover {
    background: transparent;
    color: var(--secondary);
    border-color: var(--secondary);
}
.btn-outline {
    background: transparent;
    border-color: var(--text-dark);
    color: var(--text-dark);
}
.btn-outline:hover {
    background: var(--text-dark);
    color: var(--white);
}
.btn-outline-light {
    background: transparent;
    border-color: var(--white);
    color: var(--white);
}
.btn-outline-light:hover {
    background: var(--white);
    color: var(--text-dark);
}
.btn-ghost { background: transparent; color: var(--text-muted); border: none; }
.btn-ghost:hover { color: var(--primary); }
.btn-danger { background: #8B2020; color: var(--white); border-color: #8B2020; }
.btn-danger:hover { background: transparent; color: #8B2020; }
.btn-sm  { padding: .5rem 1.4rem; font-size: .75rem; }
.btn-lg  { padding: 1rem 3rem; font-size: .88rem; }
.btn-full { width: 100%; }

/* ── Cards — Luxury ── */
.card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: var(--transition);
}
.card:hover { box-shadow: var(--shadow-md); }
.card-body  { padding: 2rem; }
.card-header {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border);
    font-family: var(--font-heading);
    font-weight: 500;
}
.card-footer {
    padding: 1.25rem 2rem;
    border-top: 1px solid var(--border);
    background: var(--bg);
}

/* ── Forms — Luxury ── */
.form-group { margin-bottom: 1.5rem; }
.form-label {
    display: block;
    margin-bottom: .5rem;
    font-weight: 600;
    font-size: .82rem;
    color: var(--text-dark);
    letter-spacing: .03em;
    text-transform: uppercase;
}
.form-control {
    width: 100%;
    padding: .85rem 1.2rem;
    border: 1px solid rgba(30,42,42,.12);
    border-radius: var(--radius);
    font-size: .92rem;
    font-family: var(--font-body);
    background: var(--white);
    color: var(--text-dark);
    transition: var(--transition);
    direction: rtl;
}
.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79,124,121,.1);
}
.form-control.is-invalid { border-color: #8B2020; }
.invalid-feedback { color: #8B2020; font-size: .8rem; margin-top: .35rem; }
textarea.form-control { resize: vertical; min-height: 120px; }
select.form-control { cursor: pointer; }

/* ── Badges — Luxury ── */
.badge {
    display: inline-flex;
    align-items: center;
    padding: .3rem .9rem;
    font-size: .72rem;
    font-weight: 600;
    letter-spacing: .05em;
    text-transform: uppercase;
}
.badge-success  { background: rgba(5,150,105,.08); color: #065F46; }
.badge-warning  { background: rgba(245,158,11,.08); color: #92400E; }
.badge-danger   { background: rgba(139,32,32,.08); color: #8B2020; }
.badge-info     { background: rgba(59,130,246,.08); color: #1E40AF; }
.badge-primary  { background: rgba(79,124,121,.08); color: var(--primary); }
.badge-secondary{ background: rgba(198,162,126,.08); color: var(--secondary); }
.badge-dark     { background: var(--text-dark); color: var(--white); }

/* ── Alerts — Luxury ── */
.alert {
    padding: 1.2rem 1.5rem;
    border-radius: var(--radius);
    margin-bottom: 1rem;
    font-size: .9rem;
    border-right: 3px solid transparent;
}
.alert-success { background: rgba(5,150,105,.06); color: #065F46; border-color: #059669; }
.alert-error   { background: rgba(139,32,32,.06); color: #8B2020; border-color: #8B2020; }
.alert-warning { background: rgba(245,158,11,.06); color: #92400E; border-color: #F59E0B; }
.alert-info    { background: rgba(59,130,246,.06); color: #1E40AF; border-color: #3B82F6; }

/* ── Tables ── */
.table-wrapper { overflow-x: auto; border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
.table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
    font-size: .9rem;
}
.table th {
    background: var(--bg);
    padding: 1rem 1.25rem;
    text-align: right;
    font-weight: 600;
    font-size: .78rem;
    letter-spacing: .05em;
    text-transform: uppercase;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border);
}
.table td {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
    color: var(--text-dark);
}
.table tbody tr:hover { background: rgba(79,124,121,.02); }
.table tbody tr:last-child td { border-bottom: none; }

/* ── Pagination — Luxury ── */
.pagination { display: flex; gap: .3rem; justify-content: center; margin-top: 3rem; flex-wrap: wrap; }
.pagination a, .pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.4rem;
    height: 2.4rem;
    padding: 0 .5rem;
    font-size: .85rem;
    font-family: var(--font-heading);
    background: transparent;
    color: var(--text-body);
    transition: var(--transition);
    border: none;
}
.pagination a:hover { color: var(--primary); }
.pagination .active span {
    color: var(--primary);
    font-weight: 700;
    border-bottom: 2px solid var(--primary);
}
.pagination .disabled span { opacity: .3; cursor: not-allowed; }

/* ── Product Card — Luxury ── */
.product-card {
    background: var(--white);
    overflow: hidden;
    transition: var(--transition);
    position: relative;
}
.product-card:hover {
    box-shadow: var(--shadow-lg);
}
.product-card__image {
    aspect-ratio: 3/4;
    overflow: hidden;
    background: var(--bg);
    display: block;
}
.product-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .8s cubic-bezier(.25,.46,.45,.94);
}
.product-card:hover .product-card__image img { transform: scale(1.06); }
.product-card__body {
    padding: 1.5rem 1rem;
    text-align: center;
}
.product-card__brand {
    font-size: .68rem;
    color: var(--secondary);
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
    margin-bottom: .4rem;
}
.product-card__name {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 500;
    margin: .2rem 0 .6rem;
    color: var(--text-dark);
    line-height: 1.4;
}
.product-card__pricing {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: .5rem;
}
.product-card__price {
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-dark);
}
.product-card__compare {
    font-size: .82rem;
    color: var(--text-muted);
    text-decoration: line-through;
    margin-right: .5rem;
}
.product-card__badge { position: absolute; top: 1rem; right: 1rem; z-index: 2; }
.product-card__cart-btn {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--text-dark);
    color: var(--white);
    padding: .9rem;
    font-family: var(--font-body);
    font-size: .75rem;
    font-weight: 600;
    letter-spacing: .1em;
    text-transform: uppercase;
    border: none;
    cursor: pointer;
    opacity: 0;
    transform: translateY(100%);
    transition: var(--transition);
}
.product-card:hover .product-card__cart-btn {
    opacity: 1;
    transform: translateY(0);
}
.product-card__cart-btn:hover {
    background: var(--primary);
}

/* ── Section Titles — Luxury ── */
.section-title { text-align: center; margin-bottom: 4rem; }
.section-title h2 {
    font-family: var(--font-heading);
    color: var(--text-dark);
    font-weight: 500;
    font-size: 2.2rem;
}
.section-title p {
    max-width: 500px;
    margin: 1rem auto 0;
    font-size: .95rem;
    color: var(--text-muted);
}
.section-title .divider {
    width: 50px;
    height: 1px;
    background: var(--secondary);
    margin: 1.2rem auto 0;
}

/* ── Utility ── */
.text-center { text-align: center; }
.text-muted  { color: var(--text-muted); }
.text-primary{ color: var(--primary); }
.text-accent { color: var(--secondary); }
.text-danger { color: #8B2020; }
.text-success{ color: #059669; }
.fw-bold     { font-weight: 700; }
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: .5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.gap-1 { gap: .5rem; }
.gap-2 { gap: 1rem; }
.d-flex { display: flex; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.hidden { display: none; }

/* ── Grid — Luxury ── */
.grid { display: grid; gap: 2rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* ── Scroll Reveal Animation ── */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity .8s cubic-bezier(.25,.46,.45,.94), transform .8s cubic-bezier(.25,.46,.45,.94);
}
.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}
.reveal-delay-1 { transition-delay: .1s; }
.reveal-delay-2 { transition-delay: .2s; }
.reveal-delay-3 { transition-delay: .3s; }
.reveal-delay-4 { transition-delay: .4s; }

@media (max-width: 1024px) {
    .grid-4 { grid-template-columns: repeat(3, 1fr); }
    h1 { font-size: 2.2rem; }
    h2 { font-size: 1.8rem; }
}
@media (max-width: 768px) {
    .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-2 { grid-template-columns: 1fr; }
    h1 { font-size: 1.8rem; }
    h2 { font-size: 1.5rem; }
    .container { padding: 0 1.25rem; }
    .section-title { margin-bottom: 2.5rem; }
    .section-title h2 { font-size: 1.6rem; }
}
@media (max-width: 480px) {
    .grid-3, .grid-4 { grid-template-columns: 1fr; }
}
