/* وارد کردن فونت از سرور گوگل */
@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@400;700&display=swap');

* {
    font-family: 'Vazirmatn', Tahoma, sans-serif;
}

/* مخصوص عناصر فرم (برای اطمینان کامل در همه مرورگرها) */
input,
select,
textarea,
button {
    font-family: 'Vazirmatn', Tahoma, sans-serif;
}

body { 
    direction: rtl;
    margin: 0; 
    padding: 20px; 
    background-color: #f4f4f4; 
    color: #333; 
}
.container { 
    max-width: 500px; 
    margin: auto; 
    background: white; 
    padding: 20px; 
    border-radius: 10px; 
    box-shadow: 0 2px 10px rgba(0,0,0,0.1); 
}

.logo { 
    text-align: center; 
    font-size: 24px; 
    font-weight: bold; 
    margin-bottom: 10px;
}

.logo-img{
    display: block;
    margin: 50px auto 50px;
    max-width: 100%;
    height: auto;
    filter: drop-shadow(2px 2px 2px #222);
    width: 60%;
}

#cart-link{
    display:inline-flex;
    float:left;
    gap:8px;
    align-items:center;
    text-decoration:none;
}

#cart-count{
    background:#e53935;
    color:#fff;
    border-radius:999px;
    padding:2px 8px;
    font-size:12px;
    position: relative;
    top:-10px;
    right:-15px;
}

.intro { 
    font-size: 18px; 
    text-align: center; 
    color: #666; 
    margin-bottom: 20px; 
}

input, select { 
    width: 100%; 
    padding: 10px; 
    margin: 10px 0; 
    border: 1px solid #ddd; 
    border-radius: 5px; 
    box-sizing: border-box; 
}


.preview-box {
    /* border: 2px dashed #ccc; */
    padding: 15px;
    margin: 20px 0;
    background: #fafafa;
    text-align: center;
    font-size: 18px;
    color: #666;
    overflow: hidden;
}

.preview-box svg {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

.btn-order { width: 100%; padding: 15px; background: #28a745; color: white; border: none; border-radius: 5px; font-weight: bold; cursor: pointer; }
.btn-tutorial { width: 100%; padding: 15px; background: #007bff; color: white; border: none; border-radius: 5px; margin-top: 10px; }


.preview-box {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.item-card {
    border: 1px solid #ddd;
    border-radius: 12px;
    padding: 15px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform 0.2s;
}

.meta-info {
    width: 100%;
    margin-top: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    border-top: 1px solid #eee;
    padding-top: 10px;
}

.dims {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    font-size: 1.2em;
    color: #555;
}

.dim-badge {
     font-family: 'Vazirmatn', Tahoma, sans-serif;
    font-size: 1.1rem;
    font-weight: 500;
    color: #34495e;
    background: #f4f6f8;
    padding: 6px 10px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
  
}
/* عددها کمی برجسته‌تر شوند */
.dim-badge strong {
    font-weight: 700;
}

/* فلش‌ها کمی ملایم‌تر */
.dim-badge::first-letter {
    font-size: 1.05rem;
    color: #7f8c8d;
}

/* ردیف پایین کارت برای تراز کردن قیمت و دکمه */
.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-top: 8px;
    gap: 10px;
}

/* دکمه مدرن، کوچک و کپسولی (تراز چپ) */
.add-btn {
    background: #27ae60;
    color: white;
    border: none;
    padding: 6px 16px;
    border-radius: 50px; /* شکل کپسولی */
    cursor: pointer;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: bold;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(39, 174, 96, 0.15);
    white-space: nowrap;
}

/* افکت حرکت ملایم به بالا هنگام رفتن موس روی دکمه */
.add-btn:hover {
    background: #219150;
    transform: translateY(-1.5px);
    box-shadow: 0 4px 10px rgba(39, 174, 96, 0.3);
}

.add-btn:active {
    transform: translateY(0);
}

.total-card {
    border: 2px solid #e6f4ea;
    background: #f8fffb;
    border-radius: 12px;
    padding: 16px;
    margin-top: 15px;
    text-align: center;
}

.total-price {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: #2c3e50;
}

.add-main-btn {
    background: #27ae60;
    color: white;
    border: none;
    padding: 10px 22px;
    border-radius: 40px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.add-main-btn:hover {
    background: #219150;
    transform: translateY(-2px);
}


#toast{
    visibility: hidden;
    min-width: 200px;
    background:#2ecc71;
    color: #fff;
    padding: 14px 20px;
    border-radius: 8px;
    position: fixed;
    bottom: 25px;
    right: 25px;
    z-index: 9999;
    font-size: 15px;
    opacity: 0;
    transition: opacity .4s, visibility .4s;
}

#toast.show {
    visibility: visible;
    opacity: 1;
}



/* استایل‌های اختصاصی سبد خرید (تکمیلی) */

/* ---------- Cart page typography & buttons ---------- */
.cart-logo-img {
    margin: 20px auto 20px !important; /* کاهش فاصله بیرونی */
    width: 40% !important;             /* کوچک‌تر کردن عرض لوگو نسبت به صفحه اصلی */
}

.cart-summary {
    margin-top: 25px;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 12px;
    border: 1px solid #bbb;
}

.cart-summary div {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 1.2rem;
    font-weight: 600;
}


.remove-btn {
    margin-top: 10px;
    background: #fee2e2;
    color: #b91c1c;
    border: none;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 20px;
    font-weight:bold;
    width: 100%;
}


.cart-page {
    font-size: 18px;
    line-height: 1.7;
}

.cart-page .item-card {
    font-size: 20px;
}

.cart-page .meta-info,
.cart-page .dims,
.cart-page .price-badge,
.cart-page .remove-btn,
.cart-page .checkout-btn,
.cart-page .back-link {
    font-size: 20px;
}

.cart-page .dim-badge {
    font-size: 20px;
}

.cart-page .price-badge {
    font-weight: 700;
}

.cart-page .remove-btn{
    width: 100%;
    border: none;
    border-radius: 8px;
    padding: 12px;
    margin-top: 10px;
    cursor: pointer;
    font-weight: 700;
}

.cart-page .remove-btn {
    background: #ffe5e5;
    color: #b30000;
}

.checkout-btn {
    display: block;
    width: 100%;
    text-align: center;
    background: #1e3a8a;
    color: white;
    padding: 15px;
    border: none;
    border-radius: 10px;
    margin-top: 10px;
    text-decoration: none;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    box-sizing: border-box;
}

.checkout-btn:hover { background: #1d4ed8; }

.back-btn {
    display: block;
    width: 100%;
    text-align: center;
    background: green;
    color: white;
    padding: 15px;
    border: none;
    border-radius: 10px;
    margin-top: 10px;
    text-decoration: none;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    box-sizing: border-box;
    
}

.back-btn:hover {
    background: #0a8f0a;
}

.link-btn{
  display: block;
    width: 100%;
    text-align: center;
    color: white;
    padding: 15px;
    border: none;
    border-radius: 10px;
    margin-top: 10px;
    text-decoration: none;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    box-sizing: border-box;  
}

.blue-btn {
    background: #1e3a8a;
}
.blue-btn:hover {
    background: #1d4ed8;
}

.green-btn{
    background: green;
}
.green-btn:hover{
    background: #0a8f0a;
}

.svg-row {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: visible;
}

.svg-container {
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: visible;
}

.svg-container svg {
    display: block;
    width: 100%;
    height: auto;
    max-width: 100%;
    overflow: visible;
}

/* --- Footer Contact Style --- */
.contact-box {
    margin-top: 100px;
    padding-top: 18px;
    border-top: 1px solid #e5e7eb;
}

.contact-title {
    margin: 10px 0 12px;
    font-size: 18px;
    font-weight: 700;
    color: #1f2937;
    text-align: center;
}

.contact-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    margin-bottom: 8px;
    /* background: #f8fafc; */
    /* border: 1px solid #e5e7eb; */
    /* border-radius: 10px; */
    font-size: 14px;
    color: #374151;
}

.contact-label {
    font-weight: 700;
    color: #111827;
    white-space: nowrap;
}

.contact-item a {
    color: #2563eb;
    text-decoration: none;
    word-break: break-word;
}

.contact-item a:hover {
    text-decoration: underline;
}

.contact-note {
    margin: 12px 0 0;
    font-size: 13px;
    line-height: 1.9;
    color: #6b7280;
    text-align: right;
}

/* موبایل */
@media (max-width: 480px) {
    .contact-item {
        flex-direction: column;
        align-items: flex-start;
    }
}
