/* =============================
   Base Styles
============================= */
* {
    box-sizing: border-box;
}

body {
    font-family: "Vazirmatn", sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f6f8;
    color: #1f2937;
    direction: rtl;
    line-height: 1.8;
    transition: background-color 0.25s ease, color 0.25s ease;
}

/* دارک مود پایه */
.dark-mode {
    background-color: #0f172a !important;
    color: #e2e8f0 !important;
}

/* =============================
   Navbar
============================= */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 30px;
    background-color: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    box-shadow: 0px 2px 10px rgba(0,0,0,0.05);
    transition: all 0.25s ease;
}

.navbar a {
    margin: 0 12px;
    color: #374151;
    text-decoration: none;
    font-weight: 500;
    font-size: 15px;
    transition: 0.2s;
}

.navbar a:hover {
    color: #2563eb;
}

.dark-mode .navbar {
    background-color: #1e293b;
    border-bottom-color: #334155;
    box-shadow: 0px 2px 12px rgba(0,0,0,0.5);
}

.dark-mode .navbar a {
    color: #e2e8f0;
}

.dark-mode .navbar a:hover {
    color: #60a5fa;
}

/* =============================
   Buttons – زیباتر و مدرن‌تر
============================= */
button,
.btn {
    padding: 10px 18px;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: #fff !important;
    border: none;
    cursor: pointer;
    text-decoration: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    transition: 0.25s ease;
    box-shadow: 0px 3px 10px rgba(37, 99, 235, 0.25);
}

button:hover,
.btn:hover {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    box-shadow: 0px 4px 14px rgba(37, 99, 235, 0.35);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid #2563eb;
    color: #2563eb !important;
    border-radius: 8px;
}

.btn-outline:hover {
    background-color: #2563eb;
    color: #fff !important;
}

/* دارک مود دکمه‌ها */
.dark-mode button,
.dark-mode .btn {
    background: linear-gradient(135deg, #60a5fa, #3b82f6);
    color: #0f172a !important;
    box-shadow: 0px 3px 10px rgba(96,165,250,0.25);
}

.dark-mode .btn:hover {
    background: linear-gradient(135deg, #93c5fd, #60a5fa);
}

.dark-mode .btn-outline {
    border-color: #93c5fd;
    color: #93c5fd !important;
}

.dark-mode .btn-outline:hover {
    background-color: #93c5fd;
    color: #0f172a !important;
}

/* =============================
   Forms
============================= */
input,
textarea,
select {
    width: 100%;
    padding: 11px;
    font-size: 16px;
    margin-bottom: 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background-color: #fff;
    transition: 0.2s;
}

input:focus,
textarea:focus,
select:focus {
    border-color: #2563eb;
    outline: none;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

.dark-mode input,
.dark-mode textarea,
.dark-mode select {
    background-color: #1e293b;
    color: #e2e8f0;
    border-color: #475569;
}

.dark-mode input:focus,
.dark-mode textarea:focus,
.dark-mode select:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 3px rgba(96,165,250,0.2);
}

/* =============================
   Tables
============================= */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 22px;
    border-radius: 8px;
    overflow: hidden;
    background-color: #ffffff;
}

table th {
    background-color: #f1f5f9;
    padding: 14px;
    font-weight: 600;
    color: #1e293b;
}

table td {
    padding: 12px;
    border-bottom: 1px solid #e2e8f0;
    color: #374151;
}

table tr:hover td {
    background-color: #f9fafb;
}

/* دارک مود */
.dark-mode table {
    background-color: #1e293b;
}

.dark-mode table th {
    background-color: #334155;
    color: #e2e8f0;
}

.dark-mode table td {
    border-bottom: 1px solid #475569;
    color: #cbd5e1;
}

.dark-mode table tr:hover td {
    background-color: #293447;
}

/* =============================
   Footer
============================= */
.site-footer {
    text-align: center;
    padding: 25px;
    background: #e5e7eb;
    margin-top: 50px;
    color: #445;
    font-size: 14px;
    border-top: 1px solid #ccc;
}

.dark-mode .site-footer {
    background: #1e293b;
    color: #cbd5e1;
    border-top-color: #334155;
}

/* =============================
   Containers
============================= */
.container,
.container-main {
    max-width: 1100px;
    margin: 40px auto;
    padding: 26px;
    background-color: #ffffff;
    border-radius: 12px;
    box-shadow: 0px 4px 18px rgba(0,0,0,0.05);
    transition: background-color 0.25s ease, color 0.25s ease;
}

.dark-mode .container,
.dark-mode .container-main {
    background-color: #1e293b;
    box-shadow: 0px 4px 18px rgba(255,255,255,0.07);
}

/* =============================
   Sections
============================= */
.section,
.hero,
.auth-bar {
    transition: 0.25s ease;
}

.dark-mode .section,
.dark-mode .hero,
.dark-mode .auth-bar {
    color: #e2e8f0;
}
