/* پالت و تایپوگرافی یکسان با صفحه‌ی اصلی (home.css) در کل سایت */
:root {
    --ink: #16212B;
    --ink-soft: #51606A;
    --paper: #EFF2EE;
    --panel: #FFFFFF;
    --steel: #35597A;
    --brass: #B9852A;
    --brass-soft: #F1E4C8;
    --line: #D2D8D2;
}

* { box-sizing: border-box; }

body {
    font-family: "Vazirmatn", "Tahoma", sans-serif;
    background: var(--paper);
    color: var(--ink);
    margin: 0;
}

.topbar {
    background: var(--ink);
    color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.9rem 1.5rem;
    border-bottom: 3px solid var(--brass);
}

.topbar .brand {
    color: #fff;
    font-weight: 800;
    font-size: 1.1rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}
.topbar .brand-logo {
    height: 32px;
    width: auto;
    max-width: 130px;
    object-fit: contain;
}

.topbar nav a, .topbar nav .link-button {
    color: #cfd7dc;
    text-decoration: none;
    margin-inline-start: 1.1rem;
    background: none;
    border: none;
    font: inherit;
    cursor: pointer;
    transition: color 0.15s;
}

.topbar nav a:hover, .topbar nav .link-button:hover { color: var(--brass); }

.inline-form { display: inline; }

.user-name { color: #8a97a0; margin-inline-start: 1rem; }

.container {
    max-width: 900px;
    margin: 2rem auto;
    padding: 0 1rem;
}
.container.wide { max-width: 1120px; }

.card {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 1.6rem;
    margin-bottom: 1.2rem;
    box-shadow: 0 10px 24px -18px rgba(22,33,43,0.25);
}

h1 { font-size: 1.6rem; font-weight: 800; }
h2 { font-size: 1.2rem; font-weight: 700; margin-top: 0; }

.messages { list-style: none; padding: 0; }
.message { padding: 0.7rem 1rem; border-radius: 8px; margin-bottom: 0.6rem; }
.message.success { background: #dcfce7; color: #166534; }
.message.error { background: #fee2e2; color: #991b1b; }
.message.info { background: #dbeafe; color: #1e40af; }

table { width: 100%; border-collapse: collapse; margin-bottom: 1rem; }
th, td { padding: 0.6rem 0.5rem; border-bottom: 1px solid var(--line); text-align: right; }
th { color: var(--ink-soft); font-weight: 600; font-size: 0.9rem; }

.status { padding: 0.2rem 0.7rem; border-radius: 20px; font-size: 0.82rem; font-weight: 600; }
.status-draft { background: #e5e7eb; color: #374151; }
.status-generating { background: var(--brass-soft); color: #7a5814; }
.status-done { background: #dcfce7; color: #166534; }
.status-failed { background: #fee2e2; color: #991b1b; }
.status-open { background: #fef3c7; color: #92400e; }
.status-answered { background: #dbeafe; color: #1e40af; }
.status-closed { background: #e5e7eb; color: #374151; }
.status-pending { background: #fef3c7; color: #92400e; }
.status-success { background: #dcfce7; color: #166534; }

.btn {
    display: inline-block;
    background: var(--steel);
    color: #fff;
    border: none;
    padding: 0.65rem 1.3rem;
    border-radius: 8px;
    cursor: pointer;
    text-decoration: none;
    font-size: 0.95rem;
    font-family: inherit;
    transition: background 0.15s;
}
.btn:hover { background: #294a63; }
.btn.secondary { background: var(--brass); color: #1a1305; }
.btn.secondary:hover { background: #a3781f; }
.btn:disabled { background: #a9b2b8; cursor: not-allowed; }

form p { margin: 0.7rem 0; }
label { font-weight: 600; font-size: 0.92rem; color: var(--ink); }
input[type=text], input[type=password], input[type=email], input[type=tel],
select, textarea, input[type=file] {
    width: 100%;
    padding: 0.55rem 0.7rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    margin-top: 0.35rem;
    font-family: inherit;
    font-size: 0.95rem;
    background: var(--panel);
    color: var(--ink);
}
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--steel);
}

.project-list a { color: var(--ink); text-decoration: none; font-weight: 600; }
.project-list a:hover { color: var(--steel); text-decoration: underline; }

.helptext { color: var(--ink-soft); font-size: 0.87rem; }
.error-box { background: #fee2e2; color: #991b1b; padding: 0.9rem 1.1rem; border-radius: 8px; }

ul.errorlist {
    list-style: none;
    margin: 0 0 1rem 0;
    padding: 0.9rem 1.1rem;
    background: #fee2e2;
    color: #991b1b;
    border-radius: 8px;
    font-weight: 600;
}
ul.errorlist li { margin: 0; }
ul.errorlist.nonfield { margin-bottom: 1rem; }
