﻿/* =========================
   General
========================= */

:root {
    --bg: #f8f5ef;
    --bg-soft: #eee7dc;
    --dark: #342c27;
    --text: #75675d;
    --green: #78816b;
    --green-dark: #5d6852;
    --border: #e8dfd3;
    --white: #ffffff;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Vazirmatn', Tahoma, sans-serif;
    background: var(--bg);
    color: var(--dark);
    line-height: 1.9;
}

a {
    text-decoration: none;
    color: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

::selection {
    background: var(--green);
    color: white;
}


/* =========================
   Header
========================= */

.site-header {
    width: 100%;
    border-bottom: 1px solid var(--border);
    background: rgba(248, 245, 239, 0.95);
}

.header-container {
    width: min(1200px, 90%);
    margin: auto;
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 20px;
    font-weight: 700;
}

.logo-icon {
    color: var(--green);
    font-size: 28px;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 35px;
}

    .main-nav a {
        font-size: 14px;
        color: var(--text);
        transition: .3s;
    }

        .main-nav a:hover,
        .main-nav a.active {
            color: var(--green-dark);
        }

.header-button {
    background: var(--green);
    color: white;
    padding: 10px 22px;
    border-radius: 5px;
    font-size: 14px;
    transition: .3s;
}

    .header-button:hover {
        background: var(--green-dark);
        transform: translateY(-2px);
    }

    .header-button span {
        margin-right: 8px;
    }


/* =========================
   Hero
========================= */
/* =========================
   Hero Banner
========================= */

.hero {
    overflow: hidden;
    padding: 85px 0 100px;
    background-image: url('/images/1.png');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}
.hero-container {
    width: min(1200px, 90%);
    min-height: 460px;
    margin: auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 50px;
}

.hero-content {
    padding-right: 20px;
}

.hero-label,
.section-label {
    color: var(--green);
    font-size: 14px;
    font-weight: 500;
    display: inline-block;
    margin-bottom: 20px;
}

    .hero-label::before {
        content: "✦";
        margin-left: 10px;
    }

.hero-content h1 {
    font-size: clamp(35px, 4vw, 55px);
    font-weight: 800;
    line-height: 1.7;
    color: var(--dark);
}

    .hero-content h1 span {
        color: var(--green);
    }

.hero-description {
    max-width: 500px;
    margin-top: 20px;
    color: var(--text);
    font-size: 16px;
    line-height: 2.2;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.hero-buttons {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: 30px;
}

.primary-button {
    background: var(--green);
    color: white;
    padding: 13px 28px;
    border-radius: 5px;
    transition: .3s;
}

    .primary-button:hover {
        background: var(--green-dark);
        transform: translateY(-3px);
    }

    .primary-button span {
        margin-right: 10px;
    }

.secondary-button {
    padding: 13px 25px;
    border: 1px solid var(--border);
    border-radius: 5px;
    color: var(--dark);
    transition: .3s;
}

    .secondary-button:hover {
        border-color: var(--green);
        color: var(--green);
    }

.hero-note {
    margin-top: 35px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: #9a8d80;
    font-size: 13px;
}

.note-line {
    width: 40px;
    height: 1px;
    background: var(--green);
}


/* =========================
   Hero Book Image
========================= */

.hero-visual {
    position: relative;
    min-height: 460px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-circle,
.book-decoration,
.floating-text {
    display: none;
}

.hero-book {
    position: relative;
    z-index: 2;
    width: 330px;
    height: 440px;
    animation: floatingBook 5s ease-in-out infinite;
}

.book-cover {
    width: 100%;
    height: 100%;
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 0;
    box-shadow: none;
    overflow: visible;
    display: block;
}

    .book-cover::before,
    .book-cover::after {
        display: none;
    }

    .book-cover img {
        width: 100%;
        height: 100%;
        object-fit: contain;
        border: none;
        border-radius: 0;
        box-shadow: 15px 20px 35px rgba(52, 44, 39, .18);
    }

.book-cover-center {
    width: 100%;
    height: 100%;
    padding: 25px;
    background: var(--green-dark);
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

    .book-cover-center h2 {
        font-size: 30px;
        line-height: 1.8;
        margin: 15px 0;
    }

.cover-symbol {
    font-size: 40px;
    color: #d6c6a1;
}

.cover-subtitle {
    font-size: 13px;
    color: #e4e0d2;
}

@keyframes floatingBook {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

/* =========================
   Hero Illustration
========================= */

.hero-visual {
    position: relative;
    height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-circle {
    position: absolute;
    width: 390px;
    height: 390px;
    background: var(--bg-soft);
    border-radius: 50%;
}

.hero-book {
    position: relative;
    z-index: 2;
    width: 260px;
    height: 370px;
    perspective: 1000px;
    animation: floatingBook 5s ease-in-out infinite;
}

.book-cover {
    width: 100%;
    height: 100%;
    background: linear-gradient(145deg, #75816a, #495542);
    border-radius: 4px 12px 12px 4px;
    box-shadow: 20px 25px 45px rgba(52, 44, 39, .2);
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 30px;
    color: white;
    overflow: hidden;
}

    .book-cover::before {
        content: "";
        position: absolute;
        top: 0;
        right: 15px;
        height: 100%;
        width: 2px;
        background: rgba(255,255,255,.15);
    }

    .book-cover::after {
        content: "";
        position: absolute;
        inset: 15px;
        border: 1px solid rgba(255,255,255,.2);
        pointer-events: none;
    }

.book-top-text {
    font-size: 12px;
    text-align: center;
    letter-spacing: 1px;
    color: #e4e0d2;
}

.book-cover-center {
    text-align: center;
}

.cover-symbol {
    font-size: 40px;
    color: #d6c6a1;
}

.book-cover-center h2 {
    font-size: 34px;
    line-height: 1.8;
    margin: 15px 0;
}

.cover-subtitle {
    font-size: 12px;
    color: #e4e0d2;
}

.book-cover-bottom {
    text-align: center;
    font-size: 13px;
}

.book-decoration {
    position: absolute;
    width: 220px;
    height: 330px;
    border-radius: 5px;
}

.decoration-one {
    background: #c9b99e;
    transform: rotate(-15deg);
    right: 60px;
}

.decoration-two {
    background: #a8ae98;
    transform: rotate(12deg);
    left: 60px;
}

.hero-book {
    z-index: 3;
}

.floating-text {
    position: absolute;
    background: white;
    padding: 12px 20px;
    border-radius: 40px;
    box-shadow: 0 10px 30px rgba(0,0,0,.07);
    font-size: 13px;
    z-index: 4;
    color: var(--text);
}

    .floating-text span {
        color: var(--green);
        margin-left: 7px;
    }

.floating-top {
    top: 55px;
    right: 10px;
}

.floating-bottom {
    bottom: 60px;
    left: 5px;
}

@keyframes floatingBook {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-15px);
    }
}


/* =========================
   Featured Books
========================= */

.featured-books {
    background: #fff;
    padding: 100px 0;
}

.section-heading {
    width: min(1200px, 90%);
    margin: 0 auto 45px;
    display: flex;
    align-items: end;
    justify-content: space-between;
}

    .section-heading h2 {
        font-size: 30px;
        font-weight: 700;
    }

.view-all {
    color: var(--green);
    font-size: 14px;
    transition: .3s;
}

    .view-all:hover {
        color: var(--green-dark);
    }

    .view-all span {
        margin-right: 8px;
    }

.books-grid {
    width: min(1200px, 90%);
    margin: auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.book-card {
    transition: .4s;
}

    .book-card:hover {
        transform: translateY(-8px);
    }

.book-card-image {
    height: 360px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.book-color-one {
    background: #ece4d8;
}

.book-color-two {
    background: #e2e5dc;
}

.book-color-three {
    background: #e8dfe0;
}

.book-card-decoration {
    position: absolute;
    font-size: 150px;
    opacity: .12;
    color: var(--dark);
}

.book-card-cover {
    width: 190px;
    height: 280px;
    box-shadow: 10px 15px 30px rgba(0,0,0,.15);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 25px;
    text-align: center;
    position: relative;
    z-index: 2;
    transition: .4s;
}

.book-card:hover .book-card-cover {
    transform: rotate(-3deg) scale(1.04);
}

.book-color-one .book-card-cover {
    background: #9b7c69;
    color: white;
}

.book-color-two .book-card-cover {
    background: #64725d;
    color: white;
}

.book-color-three .book-card-cover {
    background: #8c6870;
    color: white;
}

.book-card-cover span {
    font-size: 12px;
}

.book-card-cover h3 {
    font-size: 25px;
    line-height: 2;
}

.book-card-cover small {
    font-size: 12px;
}

.book-card-info {
    padding: 25px 5px;
}

    .book-card-info h3 {
        font-size: 19px;
        margin-bottom: 8px;
    }

    .book-card-info p {
        color: var(--text);
        font-size: 13px;
    }

.book-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 25px;
}

.book-price {
    font-size: 14px;
    font-weight: 600;
}

.book-buy {
    background: var(--green);
    color: white;
    padding: 8px 25px;
    border-radius: 4px;
    font-size: 13px;
    transition: .3s;
}

    .book-buy:hover {
        background: var(--green-dark);
    }


/* =========================
   About
========================= */

.about-section {
    padding: 100px 0;
    background: var(--bg);
}

.about-container {
    width: min(1200px, 90%);
    margin: auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 80px;
}

.about-decoration {
    height: 350px;
    background: var(--bg-soft);
    border-radius: 5px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
}

    .about-decoration::before {
        content: "";
        position: absolute;
        inset: 25px;
        border: 1px solid rgba(120,129,107,.25);
    }

.about-symbol {
    color: var(--green);
    font-size: 90px;
}

.about-small-text {
    color: var(--text);
    font-size: 13px;
    letter-spacing: 2px;
}

.about-content h2 {
    font-size: 36px;
    line-height: 1.9;
}

    .about-content h2 span {
        color: var(--green);
    }

.about-content p {
    color: var(--text);
    line-height: 2.5;
    margin-top: 20px;
}

.about-link {
    display: inline-block;
    margin-top: 30px;
    color: var(--green);
    border-bottom: 1px solid var(--green);
    padding-bottom: 5px;
}

    .about-link span {
        margin-right: 10px;
    }


/* =========================
   Footer
========================= */

.site-footer {
    background: #342c27;
    color: white;
    padding: 60px 0 25px;
    text-align: center;
}

.footer-container {
    width: min(1200px, 90%);
    margin: auto;
}

.footer-brand {
    font-size: 22px;
    font-weight: 700;
}

    .footer-brand .logo-icon {
        color: #a6b194;
    }

.site-footer p {
    color: #c4b9ae;
    font-size: 14px;
    margin-top: 10px;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin: 30px 0;
}

    .footer-links a {
        color: #c4b9ae;
        font-size: 13px;
        transition: .3s;
    }

        .footer-links a:hover {
            color: white;
        }

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,.1);
    padding-top: 20px;
    margin-top: 30px;
    font-size: 12px;
    color: #a99d92;
}


/* =========================
   Responsive
========================= */

@media (max-width: 992px) {

    .hero-container {
        gap: 20px;
    }

    .hero-content h1 {
        font-size: 38px;
    }

    .hero-visual {
        transform: scale(.85);
    }

    .about-container {
        gap: 40px;
    }

    .books-grid {
        gap: 20px;
    }

    .book-card-image {
        height: 320px;
    }
}

@media (max-width: 768px) {

    .header-container {
        height: auto;
        min-height: 80px;
        flex-wrap: wrap;
        padding: 20px 0;
        gap: 20px;
    }

    .main-nav {
        width: 100%;
        justify-content: center;
        gap: 20px;
        flex-wrap: wrap;
    }

        .main-nav a {
            font-size: 13px;
        }

    

    .hero {
        padding: 50px 0;
    }

    .hero-container {
        grid-template-columns: 1fr;
    }

    .hero-content {
        padding: 0;
        text-align: center;
    }

        .hero-content h1 {
            font-size: 36px;
        }

    .hero-description {
        margin: 20px auto 0;
    }

    .hero-buttons {
        justify-content: center;
        flex-wrap: wrap;
    }

    .hero-note {
        justify-content: center;
    }

    .hero-visual {
        height: 430px;
        transform: none;
    }

    .hero-circle {
        width: 320px;
        height: 320px;
    }

    .hero-book {
        width: 220px;
        height: 320px;
    }

    .book-decoration {
        width: 180px;
        height: 280px;
    }

    .floating-top {
        right: 0;
    }

    .floating-bottom {
        left: 0;
    }

    .section-heading {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

        .section-heading h2 {
            font-size: 25px;
        }

    .books-grid {
        grid-template-columns: 1fr;
    }

    .book-card-image {
        height: 380px;
    }

    .about-container {
        grid-template-columns: 1fr;
    }

    .about-content {
        text-align: center;
    }

        .about-content h2 {
            font-size: 30px;
        }

    .about-decoration {
        height: 280px;
    }

    .footer-links {
        flex-wrap: wrap;
        gap: 20px;
    }
}

@media (max-width: 400px) {

    .hero-content h1 {
        font-size: 30px;
    }

    .hero-visual {
        transform: scale(.85);
        margin: -30px 0;
    }

    .main-nav {
        gap: 12px;
    }

    .hero-buttons a {
        width: 100%;
    }
}
/* =========================
   Header Actions
========================= */

.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

    .header-actions form {
        margin: 0;
    }

    .header-actions > span {
        color: var(--text);
        font-size: 14px;
    }

.header-login {
    color: var(--green-dark);
    font-size: 14px;
    font-weight: 600;
    padding: 10px 18px;
    border: 1px solid var(--border);
    border-radius: 5px;
    transition: .3s;
}

    .header-login:hover {
        color: var(--green-dark);
        background: var(--bg-soft);
    }

.header-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--green);
    color: white;
    padding: 10px 22px;
    border: 1px solid var(--green);
    border-radius: 5px;
    font-family: inherit;
    font-size: 14px;
    cursor: pointer;
    transition: .3s;
}

    .header-button:hover {
        background: var(--green-dark);
        border-color: var(--green-dark);
        color: white;
        transform: translateY(-2px);
    }
/* حذف کامل قاب قبلی جلد کتاب */
.hero-visual .hero-book,
.hero-visual .book-cover {
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
    overflow: visible !important;
}

    .hero-visual .book-cover img {
        display: block;
        width: 100% !important;
        height: 100% !important;
        object-fit: contain !important;
        border: none !important;
        border-radius: 0 !important;
        box-shadow: 12px 18px 30px rgba(0, 0, 0, .15);
    }

    .hero-visual .book-cover::before,
    .hero-visual .book-cover::after {
        display: none !important;
        content: none !important;
    }
/* اعمال اجباری تصویر پس‌زمینه بخش اصلی */
.hero {
    background: linear-gradient(rgba(248, 245, 239, 0.15), rgba(248, 245, 239, 0.15)), url('/images/1.png') center center / cover no-repeat !important;
}