:root {
    color-scheme: light;
    --color-text: #0b0b0f;
    --color-text-inverse: #ffffff;
    --color-text-muted: #4e5562;
    --color-text-soft: #697180;
    --color-link: #005fa3;
    --color-heading-accent: #6100cf;
    --surface-glass: rgba(255, 255, 255, 0.28);
    --surface-glass-border: rgba(255, 255, 255, 0.45);
    --surface-elevated: rgba(255, 255, 255, 0.9);
    --surface-hover: rgba(240, 234, 255, 0.9);
    --surface-border: rgba(41, 37, 71, 0.14);
    --surface-border-strong: rgba(41, 37, 71, 0.22);
    --surface-panel: rgba(255, 255, 255, 0.86);
    --surface-card: rgba(250, 250, 253, 0.97);
    --surface-empty: rgba(255, 255, 255, 0.55);
    --surface-input: #eef1f6;
    --surface-modal: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(244, 247, 251, 0.99));
    --surface-modal-detail: rgba(246, 248, 252, 0.98);
    --surface-badge: #ece4ff;
    --surface-chip: #dcc7ff;
    --border-badge: #c8aff7;
    --border-chip: #b996f4;
    --shadow-card: 0 16px 36px rgba(19, 14, 39, 0.12);
    --shadow-card-hover: 0 20px 44px rgba(19, 14, 39, 0.18);
    --surface-overlay: rgba(15, 23, 42, 0.58);
    --hero-primary-start: #7a3cff;
    --hero-primary-end: #5a1edb;
    --hero-secondary-text: #000000;
    --why-cta-bg: #000000;
    --why-cta-text: #ffffff;
    --page-background: radial-gradient(circle at 30% 20%, #ffffff 0%, #efe6ff 40%, #dbcaff 75%, #cbb6ff 100%);
}

[data-theme="dark"] {
    color-scheme: dark;
    --color-text: #edf2ff;
    --color-text-inverse: #111827;
    --color-text-muted: #c7d0e5;
    --color-text-soft: #aeb8cf;
    --color-link: #8cc8ff;
    --color-heading-accent: #cba6ff;
    --surface-glass: rgba(14, 18, 30, 0.72);
    --surface-glass-border: rgba(167, 181, 221, 0.18);
    --surface-elevated: rgba(23, 30, 48, 0.82);
    --surface-hover: rgba(42, 52, 79, 0.92);
    --surface-border: rgba(166, 180, 219, 0.18);
    --surface-border-strong: rgba(166, 180, 219, 0.26);
    --surface-panel: rgba(19, 26, 41, 0.82);
    --surface-card: rgba(20, 27, 44, 0.9);
    --surface-empty: rgba(21, 28, 44, 0.72);
    --surface-input: rgba(11, 16, 28, 0.92);
    --surface-modal: linear-gradient(180deg, rgba(17, 24, 39, 0.98), rgba(10, 15, 29, 0.98));
    --surface-modal-detail: rgba(24, 33, 54, 0.9);
    --surface-badge: rgba(96, 67, 171, 0.28);
    --surface-chip: rgba(97, 69, 165, 0.25);
    --border-badge: rgba(172, 142, 255, 0.22);
    --border-chip: rgba(172, 142, 255, 0.24);
    --shadow-card: 0 14px 32px rgba(3, 6, 15, 0.42);
    --shadow-card-hover: 0 18px 42px rgba(3, 6, 15, 0.55);
    --surface-overlay: rgba(2, 6, 23, 0.72);
    --hero-secondary-text: #edf2ff;
    --why-cta-bg: #edf2ff;
    --why-cta-text: #111827;
    --page-background: radial-gradient(circle at 20% 20%, #1b2140 0%, #10162b 38%, #0a0f1d 72%, #050810 100%);
}

/*Custom CSS*/

#loginDiv{
    padding: 1.3rem;
    background: linear-gradient(90deg,#005fa3 0%, #6100cf 100%);
    border-radius: .5rem;
    border: 5px solid black;
}
#loginForm{
    padding: 1rem;
    border-radius: 15px;
    background: linear-gradient(25deg, #005fa3 0%, #6100cf 100%);
}

.inputBtn-Form{
    display:block;
    border-radius: 10px;
    padding: 10px;
    background: white;
    color: black;
    width: 30rem;
}
.label-Form{
    font-size: 20px;
}

/* ============================= */
/* Global Typography */
/* ============================= */

html,
body {
    font-family: 'Inter', sans-serif;
    margin: 0;
    padding: 0;
    color: var(--color-text);
    background: var(--page-background);
    min-height: 100vh;
    transition: background 0.25s ease, color 0.25s ease;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

img {
    max-width: 100%;
}

/* ============================= */
/* Links */
/* ============================= */

a {
    color: var(--color-link);
    text-decoration: none;
    transition: opacity 0.2s ease;
}

a:hover {
    opacity: 0.8;
}

.mobile-sidebar .mobile-link,
.mobile-sidebar .mobile-link:visited,
.mobile-sidebar .mobile-link:active,
.mobile-sidebar .mobile-link:hover,
.mobile-sidebar .mobile-link.active {
    color: var(--color-text) !important;
}

/* ============================= */
/* Buttons */
/* ============================= */

.btn-primary {
    background-color: #1b6ec2;
    border-color: #1861ac;
    font-weight: 500;
}

.btn-primary:hover {
    background-color: #155da6;
    border-color: #144f91;
}

.btn:focus,
.btn:active:focus,
.btn-link.nav-link:focus,
.form-control:focus,
.form-check-input:focus {
    box-shadow: 0 0 0 0.15rem rgba(37, 140, 251, 0.4);
}

/* ============================= */
/* Headings */
/* ============================= */

h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 600;
    letter-spacing: -0.3px;
}

h1 {
    font-size: clamp(2rem, 6vw, 3.5rem);
    line-height: 1.1;
    letter-spacing: -1px;
    margin-bottom: 1rem;
}

h2 {
    font-size: clamp(1.6rem, 4.4vw, 2rem);
    font-weight: 600;
}

h3 {
    font-size: 1.5rem;
    font-weight: 600;
}

h1:focus {
    outline: none;
}

/* ============================= */
/* Forms */
/* ============================= */

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder,
.form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder,
.form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* ============================= */
/* Blazor Error Boundary */
/* ============================= */

.blazor-error-boundary {
    background: #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
    position: relative;
}

.blazor-error-boundary::before {
    content: "\\26A0";
    position: absolute;
    left: 1rem;
    top: 1rem;
    font-size: 1.2rem;
}

.blazor-error-boundary::after {
    content: "An error has occurred.";
}

.highlight {
    text-decoration: underline;
    text-decoration-thickness: 4px;
    text-underline-offset: 6px;
    text-decoration-color: var(--color-heading-accent);
}

/* ============================= */
/* Hero */
/* ============================= */

.hero-buttons {
    margin-top: 1rem;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.btn-primary-custom {
    padding: 0.9rem 2rem;
    background: linear-gradient(135deg, var(--hero-primary-start), var(--hero-primary-end));
    color: #fff;
    font-weight: 600;
    border: 1.5px solid var(--hero-primary-start);
    border-radius: 8px;
    text-decoration: none;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-primary-custom:hover {
    background: transparent;
    color: var(--color-text);
}

.btn-secondary-custom {
    padding: 0.9rem 2rem;
    background: transparent;
    color: var(--hero-secondary-text);
    font-weight: 600;
    border: 1.5px solid var(--hero-primary-start);
    border-radius: 8px;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease;
}

.btn-secondary-custom:hover {
    background: var(--hero-primary-start);
    color: #fff;
}

.btn-danger-custom {
    padding: 0.85rem 1.1rem;
    border: 1.5px solid rgba(220, 38, 38, 0.5);
    border-radius: 8px;
    background: rgba(220, 38, 38, 0.1);
    color: #991b1b;
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.16s ease, background-color 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.btn-danger-custom:hover,
.btn-danger-custom:focus-visible {
    transform: translateY(-1px);
    background: #dc2626;
    border-color: #dc2626;
    color: #fff;
    outline: none;
}

.home-image {
    display: block;
    margin: 3rem auto 0;
    max-width: 800px;
    width: 100%;
    border: 1.5px solid var(--color-text);
    border-radius: 20px;
    box-shadow: var(--shadow-card);
}

.trustbar {
    display: block;
    margin: 1rem auto 4rem;
    height: 25px;
    width: auto;
    max-width: min(100%, 620px);
}

.home-page {
    width: 100%;
    padding-bottom: clamp(4rem, 10vw, 7rem);
}

.page-with-footer-space {
    padding-bottom: clamp(4rem, 10vw, 7rem);
}

/* ============================= */
/* Why Section */
/* ============================= */

.why-title {
    margin-top: 5rem;
    margin-bottom: 4.5rem;
}

.why-section {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 3.5rem;
    align-items: center;
}

.why-left img {
    width: 100%;
    border-radius: 24px;
    border: 1px solid var(--color-text);
    display: block;
    margin: 0 auto;
}

.why-right {
    text-align: left;
}

.why-item {
    padding: 1.2rem 0;
    border-top: 1px solid var(--surface-border);
}

.why-item:first-child {
    border-top: none;
}

.why-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.why-head h3 {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 600;
}

.why-head span {
    font-size: 0.9rem;
    opacity: 0.5;
    font-family: monospace;
}

.why-item p {
    margin-top: 0.4rem;
    margin-bottom: 0;
    color: var(--color-text-muted);
    line-height: 1.5;
}

.why-cta {
    display: inline-block;
    margin-top: 1.5rem;
    padding: 0.9rem 1.8rem;
    background: var(--why-cta-bg);
    color: var(--why-cta-text);
    text-decoration: none;
    font-weight: 600;
    border-radius: 8px;
    transition: transform 0.15s ease, opacity 0.15s ease;
}

.why-cta:hover {
    transform: translateY(-2px);
    opacity: 0.9;
}

/* ============================= */
/* Tutoring Offers */
/* ============================= */

.tutoring-page {
    margin-top: 2rem;
}

.tutoring-header h1 {
    margin-bottom: 0.4rem;
}

.tutoring-header p {
    margin: 0 0 2rem;
    color: var(--color-text-muted);
    font-size: 1.05rem;
}

.tutoring-header-with-action {
    position: relative;
    display: flex;
    align-items: start;
    justify-content: center;
    gap: 1rem;
}

.tutoring-header-with-action > div {
    width: 100%;
}

.tutoring-header-with-action .tutor-add-button {
    position: absolute;
    top: 0;
    right: 0;
}

.tutor-add-button {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    border: 1px solid var(--surface-border-strong);
    border-radius: 999px;
    background: var(--color-text);
    color: var(--color-text-inverse);
    font: inherit;
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    box-shadow: var(--shadow-card);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, filter 0.18s ease;
}

.tutor-add-button span {
    display: block;
    line-height: 1;
    transition: transform 0.18s ease;
}

.tutor-add-button:hover,
.tutor-add-button:focus-visible {
    transform: translateY(-2px) scale(1.04);
    border-color: var(--color-accent);
    filter: brightness(1.04);
    box-shadow:
        0 18px 34px rgba(97, 0, 207, 0.22),
        0 0 0 5px rgba(97, 0, 207, 0.12);
    outline: none;
}

.tutor-add-button:hover span,
.tutor-add-button:focus-visible span {
    transform: rotate(90deg);
}

.tutor-add-button-small {
    width: 2.55rem;
    height: 2.55rem;
    font-size: 1.45rem;
}

.tutor-filters {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
    align-items: end;
    margin-bottom: 1rem;
    padding: 1rem;
    border: 1px solid var(--surface-border);
    border-radius: 18px;
    background: var(--surface-panel);
    backdrop-filter: blur(8px);
}

.filter-field {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    text-align: left;
}

.filter-field label,
.filter-toggle span {
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--color-text);
    padding-left: 0.45rem;
}

.filter-input {
    width: 100%;
    border: 1px solid var(--surface-border);
    border-radius: 12px;
    padding: 0.8rem 0.9rem;
    background: var(--surface-input);
    color: var(--color-text);
}

.filter-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    min-height: 48px;
    text-align: left;
}

.filter-stars {
    display: inline-flex;
    align-items: center;
    gap: 0.15rem;
    min-height: 48px;
}

.filter-star-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    padding: 0;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 999px;
    transition: transform 0.15s ease, background-color 0.15s ease;
}

.filter-star-button:hover,
.filter-star-button:focus-visible {
    background: rgba(242, 171, 0, 0.12);
    transform: translateY(-1px);
    outline: none;
}

.filter-star-button .star {
    display: inline-block;
    font-size: 1.15rem;
}

.filter-actions {
    grid-column: 1 / -1;
    display: flex;
    align-items: end;
    gap: 1rem;
}

.filter-search-field {
    flex: 1 1 auto;
}

.filter-reset {
    min-height: 48px;
    border: 1px solid var(--surface-border);
    border-radius: 12px;
    background: var(--color-text);
    color: var(--color-text-inverse);
    font-weight: 600;
    padding: 0.8rem 1rem;
}

.results-summary {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 0 0.5rem;
    margin-bottom: 1rem;
    color: var(--color-text-soft);
    font-size: 0.92rem;
}

.results-sort {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.sort-trigger {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0;
    border: none;
    background: transparent;
    color: var(--color-text);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.sort-trigger:hover,
.sort-trigger:focus-visible {
    text-decoration: underline;
}

.sort-direction-trigger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.9rem;
    height: 1.9rem;
    padding: 0;
    border: none;
    border-radius: 999px;
    background: transparent;
    color: var(--color-text);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.sort-direction-trigger:hover,
.sort-direction-trigger:focus-visible {
    background: var(--surface-hover);
}

.sort-menu {
    position: absolute;
    top: calc(100% + 0.45rem);
    right: 0;
    min-width: 12rem;
    display: flex;
    flex-direction: column;
    padding: 0.4rem;
    border: 1px solid var(--surface-border);
    border-radius: 14px;
    background: var(--surface-card);
    box-shadow: var(--shadow-card);
    z-index: 10;
}

.sort-menu-item {
    width: 100%;
    padding: 0.7rem 0.85rem;
    border: none;
    border-radius: 10px;
    background: transparent;
    color: var(--color-text);
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.sort-menu-item:hover,
.sort-menu-item:focus-visible,
.sort-menu-item.active {
    background: var(--surface-hover);
}

.tutor-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.2rem;
    width: 100%;
}

.tutor-card {
    position: relative;
    display: flex;
    flex-direction: column;
    background: var(--surface-card);
    border: 1px solid var(--surface-border);
    border-radius: 16px;
    overflow: hidden;
    backdrop-filter: blur(4px);
    box-shadow: var(--shadow-card);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
    cursor: pointer;
}

.tutor-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-card-hover);
}

.tutor-card:focus-visible {
    outline: 3px solid rgba(217, 119, 6, 0.35);
    outline-offset: 3px;
}

.tutor-edit-button {
    position: absolute;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.6rem;
    height: 2.6rem;
    border: 1px solid var(--surface-border);
    border-radius: 999px;
    background: var(--surface-elevated);
    color: var(--color-text);
    font-size: 1.15rem;
    line-height: 1;
    cursor: pointer;
    box-shadow: var(--shadow-card);
    transition: transform 0.18s ease, background-color 0.18s ease, border-color 0.18s ease;
}

.tutor-edit-button:hover,
.tutor-edit-button:focus-visible {
    transform: translateY(-1px);
    background: var(--surface-hover);
    border-color: var(--border-chip);
}

.tutor-edit-button-card {
    top: 0.9rem;
    right: 0.9rem;
}

.tutor-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    object-position: center 20%;
    background: var(--surface-hover);
}

.tutor-image-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1.25rem;
    background:
        radial-gradient(circle at top, rgba(217, 119, 6, 0.14), transparent 55%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.32), rgba(148, 163, 184, 0.12));
    color: var(--color-text-soft);
}

.tutor-image-placeholder-icon {
    width: 2.4rem;
    height: 2.4rem;
    line-height: 1;
}

.tutor-image-placeholder-icon svg {
    width: 100%;
    height: 100%;
    fill: currentColor;
}

.tutor-image-placeholder-text {
    font-size: 0.88rem;
    font-weight: 600;
    text-align: center;
}

.tutor-content {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 1rem;
    text-align: left;
}

.tutor-content h3 {
    margin: 0;
    font-size: 1.2rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tutor-topline {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.8rem;
}

.tutor-topline > div {
    flex: 1 1 auto;
    min-width: 0;
}

.tutor-school {
    margin: 0;
    color: var(--color-text-soft);
    font-size: 0.95rem;
}

.expiry-badge {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.65rem;
    border-radius: 999px;
    background: var(--surface-badge);
    border: 1px solid var(--border-badge);
    color: var(--color-heading-accent);
    font-size: 0.78rem;
    font-weight: 700;
}

.expiry-icon {
    width: 0.9rem;
    height: 0.9rem;
    display: block;
    color: currentColor;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.25;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.tutor-subjects {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.subject-chip {
    padding: 0.3rem 0.6rem;
    border-radius: 999px;
    background: var(--surface-chip);
    color: #32135f;
    border: 1px solid var(--border-chip);
    font-size: 0.82rem;
    font-weight: 600;
}

.tutor-footer {
    margin-top: 0.2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.rating {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.stars {
    font-size: 1rem;
    letter-spacing: 1px;
    line-height: 1;
}

.star {
    color: #cabd97;
}

.star.filled {
    color: #f2ab00;
}

.star.half-filled {
    color: transparent;
    background: linear-gradient(90deg, #f2ab00 50%, #cabd97 50%);
    -webkit-background-clip: text;
    background-clip: text;
}

.rating-text {
    color: var(--color-text-soft);
    font-size: 0.88rem;
}

.price {
    font-weight: 700;
    color: var(--color-text);
    white-space: nowrap;
}

.empty-state {
    width: 100%;
    padding: 2rem 1.5rem;
    border-radius: 18px;
    border: 1px dashed var(--surface-border-strong);
    background: var(--surface-empty);
}

.empty-state h3 {
    margin-bottom: 0.4rem;
}

.empty-state p {
    margin: 0;
    color: var(--color-text-soft);
}

.tutor-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: var(--surface-overlay);
    backdrop-filter: blur(6px);
}

.tutor-modal {
    position: relative;
    width: min(760px, 100%);
    max-height: min(88vh, 920px);
    overflow-y: auto;
    padding: 1.75rem;
    border: 1px solid var(--surface-border);
    border-radius: 28px;
    background: var(--surface-modal);
    box-shadow: 0 28px 70px rgba(2, 6, 23, 0.24);
}

.tutor-modal-close {
    position: absolute;
    top: 1.15rem;
    right: 1.15rem;
    display: inline-grid;
    place-items: center;
    width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    border: 1px solid var(--surface-border);
    border-radius: 999px;
    background: var(--surface-elevated);
    color: var(--color-text);
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
    transition: transform 0.18s ease, background-color 0.18s ease, border-color 0.18s ease;
}

.tutor-modal-close span {
    display: block;
    line-height: 1;
}

.tutor-modal-close:hover,
.tutor-modal-close:focus-visible {
    transform: translateY(-1px);
    background: var(--surface-hover);
    border-color: var(--border-chip);
}

.tutor-edit-button-modal {
    top: 1.15rem;
    right: 4.45rem;
    width: 2.75rem;
    height: 2.75rem;
    font-size: 1.4rem;
}

.tutor-edit-button-confirm {
    background: linear-gradient(135deg, #16a34a, #22c55e);
    border-color: rgba(34, 197, 94, 0.45);
    color: #ffffff;
}

.tutor-edit-button-confirm:hover,
.tutor-edit-button-confirm:focus-visible {
    background: linear-gradient(135deg, #15803d, #16a34a);
    border-color: rgba(34, 197, 94, 0.6);
}

.tutor-modal-header {
    display: flex;
    align-items: stretch;
    gap: 1.6rem;
    margin-bottom: 1.4rem;
    padding-right: 4rem;
    padding-bottom: 1.15rem;
    border-bottom: 1px solid color-mix(in srgb, var(--surface-border) 58%, transparent);
}

.tutor-modal-image {
    width: 180px;
    height: auto;
    min-height: 230px;
    border-radius: 24px;
    object-fit: cover;
    object-position: center 20%;
    background: var(--surface-hover);
    flex-shrink: 0;
    align-self: stretch;
    border: 1px solid var(--surface-border);
    box-shadow: var(--shadow-card);
}

.tutor-modal-image-placeholder {
    min-height: 230px;
}

.tutor-create-image {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--surface-chip);
    color: var(--color-text);
    font-size: clamp(3rem, 8vw, 4.5rem);
    font-weight: 800;
    box-shadow: none;
}

.tutor-modal-header-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
    text-align: left;
    padding: 0.2rem 0 0.1rem;
}

.tutor-modal-intro {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.tutor-modal-kicker {
    margin: 0;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--color-heading-accent);
}

.tutor-modal-header-content h2 {
    margin: 0;
    font-size: clamp(1.8rem, 4vw, 2.35rem);
    line-height: 1.05;
}

.tutor-modal-school {
    margin: 0;
    color: var(--color-text-soft);
    font-size: 1rem;
}

.tutor-modal-email {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    width: fit-content;
    color: var(--color-text-soft);
    text-decoration: none;
    font-weight: 400;
}

.tutor-modal-email:hover,
.tutor-modal-email:focus-visible {
    color: var(--color-link);
    text-decoration: underline;
}

.tutor-modal-description {
    margin: 0;
    max-width: 62ch;
    text-align: left;
    color: var(--color-text-muted);
    line-height: 1.65;
}

.tutor-modal-description.collapsed {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

.tutor-modal-description.expanded {
    display: block;
}

.tutor-modal-highlights {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.tutor-highlight-card {
    padding: 1.15rem 1.2rem;
    border-radius: 22px;
    border: 1px solid var(--surface-border);
    background: linear-gradient(180deg, var(--surface-card), var(--surface-modal-detail));
    box-shadow: var(--shadow-card);
}

.tutor-highlight-card-price {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(217, 119, 6, 0.1)), var(--surface-card);
    border-color: rgba(245, 158, 11, 0.3);
}

.tutor-highlight-card-price .tutor-highlight-value {
    margin-top: 0.9rem;
}

.tutor-highlight-card-rating {
    background: linear-gradient(135deg, rgba(97, 69, 165, 0.18), rgba(29, 78, 216, 0.08)), var(--surface-card);
}

.tutor-highlight-heading {
    display: flex;
    align-items: baseline;
    gap: 0.35rem;
    margin-bottom: 0.55rem;
}

.tutor-highlight-label {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--color-heading-accent);
}

.tutor-highlight-meta {
    color: var(--color-text-soft);
    font-size: 0.9rem;
}

.tutor-highlight-value {
    font-size: clamp(1.65rem, 4vw, 2.2rem);
    font-weight: 800;
    line-height: 1;
    color: var(--color-text);
}

.tutor-highlight-value span {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--color-text-soft);
}

.tutor-highlight-rating {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
}

.tutor-highlight-rating-value {
    font-size: clamp(1.55rem, 4vw, 2rem);
    font-weight: 800;
    color: var(--color-text);
}

.tutor-highlight-stars {
    display: inline-flex;
    align-items: center;
    gap: 0.12rem;
    font-size: 1.4rem;
    line-height: 1;
}

.tutor-modal-email-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.65rem;
    height: 1.65rem;
    border-radius: 999px;
    background: var(--surface-chip);
    border: 1px solid var(--border-chip);
    color: var(--color-heading-accent);
    flex-shrink: 0;
}

.tutor-modal-email-icon svg {
    width: 0.95rem;
    height: 0.95rem;
    fill: currentColor;
}

.tutor-modal-subjects {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    margin-bottom: 1.5rem;
}

.tutor-modal-subject-chip {
    transition: transform 0.16s ease, background-color 0.16s ease, border-color 0.16s ease;
}

.tutor-modal-subject-chip:hover {
    transform: translateY(-1px);
    background: var(--surface-badge);
    border-color: var(--border-badge);
}

.tutor-modal-body {
    display: grid;
    gap: 1.15rem;
}

.tutor-modal-section {
    padding: 1.15rem 1.2rem;
    border-radius: 20px;
    border: 1px solid var(--surface-border-strong);
    background: var(--surface-modal-detail);
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.07);
}

.tutor-modal-secondary {
    background: transparent;
    padding: 0;
    border: none;
}

.tutor-section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.7rem;
}

.tutor-section-heading h3 {
    margin: 0;
    font-size: 1.02rem;
    color: var(--color-text);
}

.tutor-inline-toggle {
    border: none;
    background: transparent;
    color: var(--color-link);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    padding: 0;
}

.tutor-inline-toggle:hover,
.tutor-inline-toggle:focus-visible {
    text-decoration: underline;
}

.tutor-secondary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
}

.tutor-secondary-item {
    display: flex;
    flex-direction: column;
    gap: 0.28rem;
    padding: 0.95rem 1rem;
    border-radius: 18px;
    border: 1px solid var(--surface-border);
    background: color-mix(in srgb, var(--surface-card) 74%, transparent);
}

.tutor-secondary-label {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--color-text-soft);
}

.tutor-secondary-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-text-muted);
}

.tutor-modal-details {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.9rem;
}

.tutor-detail-item {
    display: flex;
    flex-direction: column;
    gap: 0.22rem;
    padding: 0.9rem 1rem;
    border: 1px solid var(--surface-border);
    border-radius: 16px;
    background: var(--surface-modal-detail);
}

.tutor-detail-item-rating {
    align-items: center;
    text-align: center;
}

.tutor-detail-label {
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--color-heading-accent);
}

.tutor-detail-link {
    color: var(--color-text);
    text-decoration: none;
    word-break: break-word;
}

.tutor-detail-link:hover,
.tutor-detail-link:focus-visible {
    text-decoration: underline;
}

.tutor-detail-rating {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
}

.tutor-detail-rating-value {
    font-weight: 700;
    color: var(--color-text);
}

.tutor-modal-actions {
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.tutor-modal-cta {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: flex-end;
    gap: 0.8rem;
}

.tutor-request-subject-field {
    flex: 1 1 13rem;
    max-width: 18rem;
    text-align: left;
}

.tutor-request-subject-field span {
    display: block;
    margin-bottom: 0.35rem;
    color: var(--color-text-muted);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.tutor-request-button {
    border: none;
    border-radius: 999px;
    min-height: 3.4rem;
    min-width: min(100%, 18rem);
    padding: 0.95rem 1.7rem;
    background: linear-gradient(135deg, #d97706, #f59e0b);
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    box-shadow: 0 16px 30px rgba(217, 119, 6, 0.25);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.tutor-request-button:hover,
.tutor-request-button:focus-visible {
    transform: translateY(-1px);
    box-shadow: 0 18px 32px rgba(217, 119, 6, 0.32);
}

.tutor-request-hint {
    margin: 0;
    color: var(--color-text-soft);
    text-align: right;
}

.tutor-edit-modal .tutor-modal-header {
    margin-bottom: 1.1rem;
}

.tutor-edit-subtitle {
    margin: 0;
    color: var(--color-text-soft);
    line-height: 1.55;
}

.tutor-edit-modal .tutor-modal-school {
    margin-top: 0.25rem;
}

.tutor-edit-form {
    gap: 1.4rem;
}

.tutor-edit-form .tutor-modal-body {
    gap: 1.5rem;
}

.tutor-edit-form .tutor-modal-section {
    padding: 1.25rem 1.25rem 1.35rem;
}

.tutor-edit-metrics-section .offer-form-layout {
    margin: 0;
}

.tutor-create-modal .offer-form-field {
    align-items: stretch;
}

.tutor-create-modal .offer-form-field label {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0;
    text-align: left;
}

.tutor-create-modal .offer-form-input,
.tutor-create-modal .offer-form-input-prefix-wrap,
.tutor-create-modal .subject-selection-input-row {
    width: 100%;
}

.tutor-create-modal .tutor-edit-actions {
    gap: 0.85rem;
}

.tutor-edit-validation {
    margin: 0;
    padding-left: 1.2rem;
}

.tutor-edit-mobile-actions {
    display: none;
}

.tutor-edit-mobile-save {
    width: 100%;
    min-height: 52px;
    border: none;
    border-radius: 16px;
    background: linear-gradient(135deg, #16a34a, #22c55e);
    color: #ffffff;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 16px 28px rgba(34, 197, 94, 0.24);
    transition: transform 0.16s ease, box-shadow 0.16s ease, background-color 0.16s ease;
}

.tutor-edit-mobile-save:hover,
.tutor-edit-mobile-save:focus-visible {
    transform: translateY(-1px);
    background: linear-gradient(135deg, #15803d, #16a34a);
    box-shadow: 0 18px 30px rgba(34, 197, 94, 0.3);
    outline: none;
}

/* ============================= */
/* Profile / Tutor Offer Form */
/* ============================= */

.profile-page {
    position: relative;
    width: 100%;
    margin-top: clamp(1.4rem, 3vw, 2.4rem);
    text-align: left;
}

.profile-kicker {
    margin: 0 0 0.35rem;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--color-heading-accent);
}

.profile-subtitle {
    max-width: 58ch;
    margin: 0;
    color: var(--color-text-muted);
    font-size: clamp(1rem, 1.5vw, 1.14rem);
    line-height: 1.65;
}

.profile-hero {
    position: relative;
    display: grid;
    gap: clamp(1rem, 2.4vw, 1.6rem);
    align-items: stretch;
    margin-bottom: clamp(1.25rem, 2.6vw, 2rem);
    padding: clamp(1.15rem, 2.6vw, 1.8rem);
    overflow: hidden;
    border: 1px solid var(--surface-border);
    border-radius: 28px;
    background: linear-gradient(135deg, color-mix(in srgb, var(--surface-card) 96%, #e0f2fe 4%), var(--surface-card));
    box-shadow: var(--shadow-card);
}

.profile-hero::after {
    content: none;
}

.profile-hero-main {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(150px, 0.22fr) minmax(0, 1fr);
    gap: clamp(1rem, 2.5vw, 1.55rem);
    align-items: stretch;
}

.profile-avatar-shell {
    position: relative;
    width: 100%;
    min-height: 100%;
    padding: 0.42rem;
    border-radius: 30px;
    background: color-mix(in srgb, var(--surface-panel) 92%, rgba(14, 165, 233, 0.08));
    box-shadow: 0 12px 26px rgba(15, 23, 42, 0.1);
}

.profile-avatar-shell.is-empty {
    width: min(168px, 100%);
    min-height: auto;
    aspect-ratio: 1;
    align-self: center;
}

.profile-avatar-shell.has-image {
    align-self: stretch;
}

.profile-avatar-shell::after {
    content: none;
}

.profile-avatar-upload-label {
    cursor: pointer;
    overflow: hidden;
    transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

.profile-avatar-upload-label:hover,
.profile-avatar-upload-label:focus-within {
    transform: translateY(-2px);
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.14);
}

.profile-avatar {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 20%;
    border-radius: 24px;
    background: var(--surface-hover);
}

.profile-avatar-placeholder {
    display: grid;
    place-items: center;
    width: 100%;
    height: 100%;
    border-radius: 24px;
    background: var(--surface-panel);
    color: var(--color-heading-accent);
    font-size: 3.35rem;
    font-weight: 800;
}

.profile-avatar-plus {
    display: grid;
    place-items: center;
    width: 64px;
    height: 64px;
    border: 1px solid color-mix(in srgb, var(--color-heading-accent) 44%, var(--surface-border));
    border-radius: 20px;
    background: color-mix(in srgb, var(--surface-elevated) 88%, var(--color-heading-accent) 12%);
    color: var(--color-heading-accent);
    font-size: 2.8rem;
    font-weight: 500;
    line-height: 1;
    transition: transform 0.16s ease, background-color 0.16s ease;
}

.profile-avatar-upload-label:hover .profile-avatar-plus,
.profile-avatar-upload-label:focus-within .profile-avatar-plus {
    transform: scale(1.05);
}

.profile-avatar-overlay {
    position: absolute;
    inset: 0.42rem;
    display: grid;
    place-items: center;
    border-radius: 24px;
    background: rgba(8, 13, 26, 0.58);
    color: #ffffff;
    font-size: 0.94rem;
    font-weight: 800;
    opacity: 0;
    transition: opacity 0.16s ease;
}

.profile-avatar-upload-label:hover .profile-avatar-overlay,
.profile-avatar-upload-label:focus-within .profile-avatar-overlay {
    opacity: 1;
}

.profile-avatar-placeholder-small {
    width: 112px;
    height: 112px;
    border-radius: 20px;
    flex: 0 0 auto;
    font-size: 2rem;
}

.profile-hero-copy h1 {
    max-width: 12ch;
    margin: 0 0 0.65rem;
    font-size: clamp(2.25rem, 5vw, 4.2rem);
}

.profile-upload-input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.profile-upload-message {
    margin: -0.4rem 0 1.35rem;
    padding: 0.8rem 1rem;
    border: 1px solid rgba(34, 197, 94, 0.25);
    border-radius: 16px;
    background: rgba(34, 197, 94, 0.1);
    color: var(--color-text);
    font-weight: 650;
}

.profile-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.12fr) minmax(320px, 0.88fr);
    gap: clamp(1rem, 2.2vw, 1.55rem);
    align-items: start;
}

.offer-form-card,
.profile-detail-panel,
.profile-tutor-panel,
.profile-state-card,
.auth-shell {
    border: 1px solid var(--surface-border);
    border-radius: 24px;
    background: var(--surface-card);
    backdrop-filter: blur(8px);
    box-shadow: var(--shadow-card);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.profile-detail-panel:hover,
.profile-tutor-panel:hover {
    border-color: var(--surface-border-strong);
}

.profile-detail-panel,
.profile-tutor-panel,
.profile-state-card,
.auth-shell {
    padding: clamp(1.3rem, 2.6vw, 1.8rem);
    text-align: left;
}

.profile-detail-header {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.profile-detail-header h2 {
    margin: 0;
    font-size: clamp(1.35rem, 2.6vw, 2rem);
}

.profile-info-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.05rem;
}

.profile-info-item-wide {
    grid-column: 1 / -1;
}

.profile-edit-form {
    display: flex;
    flex-direction: column;
    gap: 1.05rem;
}

.profile-edit-actions {
    display: flex;
    justify-content: flex-end;
}

.profile-save-message {
    margin: 0;
    padding: 0.8rem 1rem;
    border: 1px solid rgba(34, 197, 94, 0.25);
    border-radius: 16px;
    background: rgba(34, 197, 94, 0.1);
    color: var(--color-text);
    font-weight: 650;
}

.profile-tutor-panel {
    position: relative;
    overflow: hidden;
    background: var(--surface-card);
}

.profile-tutor-metrics {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.9rem;
    margin: 1.05rem 0 1.25rem;
}

.profile-tutor-metrics > div {
    min-height: 122px;
    padding: 1rem;
    border: 1px solid color-mix(in srgb, var(--surface-border) 78%, rgba(14, 165, 233, 0.24));
    border-radius: 18px;
    background: color-mix(in srgb, var(--surface-panel) 88%, rgba(255, 255, 255, 0.08));
}

.profile-tutor-metrics span,
.profile-tutor-section > span {
    display: block;
    margin-bottom: 0.48rem;
    color: var(--color-text-muted);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.profile-tutor-metrics strong {
    color: var(--color-text);
    font-size: clamp(1.35rem, 2.6vw, 1.85rem);
    line-height: 1.1;
}

.profile-stars {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: clamp(0.06rem, 0.25vw, 0.14rem);
    line-height: 1;
    max-width: 100%;
}

.profile-star {
    display: inline-flex;
    width: min(1.86rem, calc((100% - 0.56rem) / 5));
    aspect-ratio: 1;
    flex: 0 1 min(1.86rem, calc((100% - 0.56rem) / 5));
}

.profile-star-svg {
    display: block;
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 4px 7px rgba(255, 179, 0, 0.22));
}

.profile-star-shape {
    stroke: rgba(138, 83, 0, 0.58);
    stroke-width: 0.62;
    stroke-linejoin: round;
}

.profile-star-sheen {
    fill: rgba(255, 255, 255, 0.06);
    transform: translateY(-0.35px) scale(0.82);
    transform-origin: center;
    mix-blend-mode: screen;
    pointer-events: none;
}

.profile-star.empty .profile-star-svg {
    filter: drop-shadow(0 3px 7px rgba(40, 36, 24, 0.12));
}

.profile-star.empty .profile-star-sheen {
    fill: rgba(255, 255, 255, 0.08);
}

@media (min-width: 1100px) {
    .profile-star {
        width: min(2.05rem, calc((100% - 0.56rem) / 5));
        flex-basis: min(2.05rem, calc((100% - 0.56rem) / 5));
    }
}

.profile-tutor-section {
    position: relative;
    z-index: 1;
    margin-bottom: 1.15rem;
}

.profile-subject-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.profile-subject-list .subject-chip {
    padding: 0.48rem 0.72rem;
    font-size: 0.86rem;
    box-shadow: 0 8px 16px rgba(97, 0, 207, 0.08);
}

.profile-tutor-description,
.profile-tutor-muted,
.profile-tutor-empty p,
.profile-tutor-empty small {
    position: relative;
    z-index: 1;
    color: var(--color-text-muted);
    line-height: 1.65;
}

.profile-tutor-description {
    margin: 0;
}

.profile-tutor-delete-button {
    padding: 0.65rem 0.9rem;
    white-space: nowrap;
}

.profile-delete-message {
    margin-top: 1rem;
}

.profile-tutor-empty {
    position: relative;
    z-index: 1;
    padding: 1.1rem;
    border: 1px dashed color-mix(in srgb, var(--surface-border-strong) 70%, rgba(14, 165, 233, 0.3));
    border-radius: 18px;
    background: color-mix(in srgb, var(--surface-panel) 80%, transparent);
}

.profile-tutor-empty strong {
    display: block;
    margin-bottom: 0.45rem;
    color: var(--color-text);
    font-size: 1.04rem;
}

.profile-tutor-empty p {
    margin: 0;
}

.profile-tutor-empty small {
    display: block;
    margin-top: 0.75rem;
    font-weight: 650;
}

.profile-state-card {
    max-width: 760px;
}

.profile-state-card h1 {
    margin-bottom: 0.5rem;
}

.profile-state-card p {
    color: var(--color-text-muted);
}

.profile-state-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.1rem;
}

.offer-form-card {
    padding: 1.4rem;
    text-align: left;
}

.auth-page {
    margin-top: 2rem;
}

.auth-shell {
    max-width: 860px;
    margin: 0 auto;
}

.auth-header {
    margin-bottom: 1rem;
}

.auth-header h1 {
    margin: 0;
}

.auth-mode-switch {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
    padding: 0.35rem;
    margin-bottom: 1.2rem;
    border: 1px solid var(--surface-border);
    border-radius: 16px;
    background: var(--surface-panel);
}

.auth-mode-switch button {
    min-height: 44px;
    border: none;
    border-radius: 12px;
    background: transparent;
    color: var(--color-text-muted);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.auth-mode-switch button.active {
    background: var(--surface-card);
    color: var(--color-heading-accent);
    box-shadow: var(--shadow-card);
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.auth-message {
    margin: 0;
    padding: 0.85rem 1rem;
    border-radius: 14px;
    background: rgba(0, 95, 163, 0.12);
    border: 1px solid rgba(0, 95, 163, 0.24);
    color: var(--color-text);
}

.auth-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.75rem;
}

.registration-progress {
    display: grid;
    gap: 0.45rem;
    margin-bottom: 1rem;
    color: var(--color-text-muted);
    font-size: 0.9rem;
    font-weight: 700;
}

.registration-progress div {
    height: 10px;
    overflow: hidden;
    border-radius: 999px;
    background: var(--surface-panel);
    border: 1px solid var(--surface-border);
}

.registration-progress i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #005fa3, #6100cf);
}

.profile-upload-box {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid var(--surface-border);
    border-radius: 18px;
    background: var(--surface-panel);
}

.profile-upload-box-crop {
    align-items: flex-start;
}

.registration-image-step {
    display: flex;
    align-items: flex-start;
    gap: 1.2rem;
    padding: 1rem;
    border: 1px solid var(--surface-border);
    border-radius: 18px;
    background: var(--surface-panel);
}

.registration-avatar-shell {
    width: min(220px, 42vw);
    min-height: auto;
    aspect-ratio: 1;
    flex: 0 0 auto;
}

.registration-avatar-shell.has-image {
    align-self: flex-start;
}

.registration-avatar-crop-frame {
    position: relative;
    display: block;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: 24px;
    background: var(--surface-hover);
}

.registration-avatar-preview {
    position: absolute;
    display: block;
    max-width: none;
    object-fit: fill;
    transform: translate(-50%, -50%);
}

.registration-avatar-overlay svg {
    width: 2.1rem;
    height: 2.1rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.profile-upload-controls {
    flex: 1 1 260px;
    min-width: 0;
}

.registration-image-controls {
    padding-top: 0.25rem;
}

.image-crop-frame {
    position: relative;
    width: 220px;
    height: 220px;
    flex: 0 0 auto;
    overflow: hidden;
    border: 2px solid var(--border-chip);
    border-radius: 24px;
    background: var(--surface-hover);
}

.image-crop-frame::after {
    content: "";
    position: absolute;
    inset: 16px;
    border: 1px solid rgba(255, 255, 255, 0.82);
    border-radius: 18px;
    pointer-events: none;
    box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.14);
}

.image-crop-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform-origin: center;
}

.crop-controls {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 0.6rem 0.75rem;
    align-items: center;
    margin-top: 1rem;
}

.crop-controls label {
    margin: 0;
    font-size: 0.88rem;
}

.crop-controls label.is-disabled {
    color: var(--color-text-soft);
    opacity: 0.58;
}

.crop-slider {
    width: 100%;
    height: 2rem;
    margin: 0;
    padding: 0;
    appearance: none;
    -webkit-appearance: none;
    background: transparent;
    accent-color: var(--color-heading-accent);
    cursor: pointer;
    touch-action: pan-y;
}

.crop-slider:disabled {
    cursor: not-allowed;
    opacity: 0.52;
}

.crop-slider:focus-visible {
    outline: none;
}

.crop-slider::-webkit-slider-runnable-track {
    height: 0.5rem;
    border: 1px solid color-mix(in srgb, var(--color-heading-accent) 28%, var(--surface-border));
    border-radius: 999px;
    background: color-mix(in srgb, var(--surface-elevated) 82%, var(--color-heading-accent) 18%);
}

.crop-slider:disabled::-webkit-slider-runnable-track {
    border-color: var(--surface-border);
    background: var(--surface-input);
}

.crop-slider::-webkit-slider-thumb {
    width: 1.35rem;
    height: 1.35rem;
    margin-top: -0.47rem;
    appearance: none;
    -webkit-appearance: none;
    border: 3px solid var(--surface-card);
    border-radius: 50%;
    background: var(--color-heading-accent);
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.18);
    transition: transform 0.14s ease, box-shadow 0.14s ease;
}

.crop-slider:disabled::-webkit-slider-thumb {
    background: var(--color-text-soft);
    box-shadow: none;
}

.crop-slider:hover::-webkit-slider-thumb,
.crop-slider:focus-visible::-webkit-slider-thumb {
    transform: scale(1.08);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.24);
}

.crop-slider::-moz-range-track {
    height: 0.5rem;
    border: 1px solid color-mix(in srgb, var(--color-heading-accent) 28%, var(--surface-border));
    border-radius: 999px;
    background: color-mix(in srgb, var(--surface-elevated) 82%, var(--color-heading-accent) 18%);
}

.crop-slider:disabled::-moz-range-track {
    border-color: var(--surface-border);
    background: var(--surface-input);
}

.crop-slider::-moz-range-progress {
    height: 0.5rem;
    border-radius: 999px;
    background: color-mix(in srgb, var(--color-heading-accent) 76%, #ffffff 24%);
}

.crop-slider:disabled::-moz-range-progress {
    background: var(--surface-input);
}

.crop-slider::-moz-range-thumb {
    width: 1.35rem;
    height: 1.35rem;
    border: 3px solid var(--surface-card);
    border-radius: 50%;
    background: var(--color-heading-accent);
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.18);
    transition: transform 0.14s ease, box-shadow 0.14s ease;
}

.crop-slider:disabled::-moz-range-thumb {
    background: var(--color-text-soft);
    box-shadow: none;
}

.crop-slider:hover::-moz-range-thumb,
.crop-slider:focus-visible::-moz-range-thumb {
    transform: scale(1.08);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.24);
}

.registration-image-label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--color-text-muted);
    font-weight: 700;
}

.profile-upload-box label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--color-text-muted);
    font-weight: 700;
}

.profile-upload-box p {
    margin: 0.5rem 0 0;
    color: var(--color-text-muted);
    overflow-wrap: anywhere;
}

.offer-form-header {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.offer-form-header h2 {
    margin: 0;
}

.offer-form-success {
    margin: 0 0 1rem;
    padding: 0.85rem 1rem;
    border-radius: 14px;
    background: rgba(34, 197, 94, 0.12);
    border: 1px solid rgba(34, 197, 94, 0.28);
    color: var(--color-text);
}

.offer-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.offer-form-layout {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.offer-form-field {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.offer-form-field-full {
    grid-column: 1 / -1;
}

.offer-form-field label {
    font-weight: 600;
    color: var(--color-text-muted);
}

.offer-form-input {
    width: 100%;
    min-height: 48px;
    box-sizing: border-box;
    padding: 0.8rem 0.9rem;
    border: 1px solid rgba(41, 37, 71, 0.28);
    border-radius: 12px;
    background: var(--surface-input);
    color: var(--color-text);
    font: inherit;
    line-height: 1.35;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
    transition: border-color 0.16s ease, box-shadow 0.16s ease, background-color 0.16s ease;
}

.offer-form-input::placeholder {
    color: var(--color-text-soft);
    opacity: 1;
}

.offer-form-input:focus,
.offer-form-input:focus-visible {
    outline: none;
    border-color: rgba(97, 0, 207, 0.58);
    background: #f6f1ff;
    box-shadow: 0 0 0 5px rgba(97, 0, 207, 0.18);
}

.offer-form-input-prefix-wrap {
    position: relative;
    display: flex;
}

.offer-form-input-prefix {
    position: absolute;
    top: 50%;
    left: 1rem;
    transform: translateY(-50%);
    color: var(--color-text-soft);
    font-weight: 600;
    pointer-events: none;
}

.offer-form-input-with-prefix {
    padding-left: 3.75rem;
}

.offer-form-textarea {
    min-height: 104px;
    resize: vertical;
}

.subject-selection-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.subject-selection-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.6rem 0.85rem;
    border: 1px solid var(--border-chip);
    border-radius: 999px;
    background: var(--surface-chip);
    color: #2c0d5b;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.16s ease, background-color 0.16s ease, border-color 0.16s ease;
}

.subject-selection-tag-label {
    position: relative;
    display: inline-block;
}

.subject-selection-tag-label::after {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 2px;
    background: currentColor;
    transform: translateY(-50%) scaleX(0);
    transform-origin: left center;
    transition: transform 0.22s ease;
}

.subject-selection-tag:hover,
.subject-selection-tag:focus-visible {
    transform: translateY(-1px);
    background: var(--surface-badge);
    border-color: var(--border-badge);
    outline: none;
}

.subject-selection-tag:hover .subject-selection-tag-label::after,
.subject-selection-tag:focus-visible .subject-selection-tag-label::after {
    transform: translateY(-50%) scaleX(1);
}

.subject-selection-tag-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.1rem;
    height: 1.1rem;
    border-radius: 999px;
    background: rgba(36, 29, 76, 0.12);
    color: inherit;
    font-size: 0.9rem;
    line-height: 1;
}

.subject-selection-input-row {
    display: flex;
    gap: 0.75rem;
    align-items: stretch;
}

.subject-selection-input-row .offer-form-input {
    border-color: color-mix(in srgb, var(--border-chip) 74%, var(--surface-border-strong) 26%);
    background:
        linear-gradient(180deg, color-mix(in srgb, var(--surface-chip) 30%, transparent), transparent),
        var(--surface-input);
}

.subject-selection-add-button {
    flex: 0 0 auto;
    min-height: 48px;
    padding: 0.75rem 0.95rem;
    border: 1px solid color-mix(in srgb, var(--border-chip) 55%, var(--surface-border-strong) 45%);
    border-radius: 12px;
    background: rgba(244, 241, 251, 0.98);
    color: #27143f;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.08);
    transition: transform 0.16s ease, background-color 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, opacity 0.16s ease;
}

.subject-selection-add-button:hover,
.subject-selection-add-button:focus-visible {
    transform: translateY(-1px);
    background: #e7dcff;
    border-color: #a985f0;
    box-shadow: 0 9px 18px rgba(97, 0, 207, 0.16);
    opacity: 1;
    outline: none;
}

[data-theme="dark"] .tutor-modal-header {
    padding-bottom: 0;
    border-bottom: none;
}

[data-theme="dark"] .tutor-modal-header-content {
    padding: 0;
}

[data-theme="dark"] .tutor-modal-section {
    border: 1px solid var(--surface-border);
    background: var(--surface-modal-detail);
    box-shadow: none;
}

[data-theme="dark"] .tutor-edit-subtitle {
    color: var(--color-text-muted);
}

[data-theme="dark"] .offer-form-field label {
    color: var(--color-text);
}

[data-theme="dark"] .offer-form-input {
    border: 1px solid var(--surface-border);
    background: var(--surface-input);
    box-shadow: none;
}

[data-theme="dark"] .offer-form-input:focus,
[data-theme="dark"] .offer-form-input:focus-visible {
    border-color: rgba(172, 142, 255, 0.42);
    background: var(--surface-input);
    box-shadow: 0 0 0 4px rgba(172, 142, 255, 0.14);
}

[data-theme="dark"] .offer-form-input-prefix {
    left: 0.9rem;
}

[data-theme="dark"] .offer-form-input-with-prefix {
    padding-left: 3.75rem;
}

[data-theme="dark"] .subject-chip,
[data-theme="dark"] .subject-selection-tag {
    background: var(--surface-chip);
    color: var(--color-heading-accent);
    border-color: var(--border-chip);
}

[data-theme="dark"] .subject-selection-tag-remove {
    background: rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] .subject-selection-input-row .offer-form-input {
    border-color: var(--border-chip);
    background:
        linear-gradient(180deg, color-mix(in srgb, var(--surface-chip) 22%, transparent), transparent),
        var(--surface-input);
}

[data-theme="dark"] .subject-selection-add-button {
    border: 1px solid var(--surface-border-strong);
    background: rgba(255, 255, 255, 0.06);
    color: var(--color-text);
    box-shadow: 0 6px 14px rgba(3, 6, 15, 0.18);
}

[data-theme="dark"] .subject-selection-add-button:hover,
[data-theme="dark"] .subject-selection-add-button:focus-visible {
    background: rgba(255, 255, 255, 0.12);
    border-color: var(--surface-border);
    box-shadow: 0 8px 16px rgba(3, 6, 15, 0.24);
}

[data-theme="dark"] .btn-danger-custom {
    border-color: rgba(248, 113, 113, 0.44);
    background: rgba(248, 113, 113, 0.12);
    color: #fecaca;
}

[data-theme="dark"] .btn-danger-custom:hover,
[data-theme="dark"] .btn-danger-custom:focus-visible {
    background: #b91c1c;
    border-color: #ef4444;
    color: #fff;
}

.offer-form-actions {
    display: flex;
    justify-content: flex-end;
}

/* ============================= */
/* Tutor Dashboard */
/* ============================= */

.dashboard-page {
    width: 100%;
    margin-top: 1.5rem;
    text-align: left;
}

.dashboard-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1.25rem;
    align-items: end;
    margin-bottom: 1.35rem;
}

.dashboard-header h1 {
    margin: 0 0 0.45rem;
}

.dashboard-header p {
    max-width: 62ch;
    margin: 0;
    color: var(--color-text-muted);
    font-size: 1.04rem;
}

.dashboard-kicker,
.dashboard-section-kicker {
    margin: 0 0 0.35rem;
    color: var(--color-heading-accent);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.dashboard-quick-action {
    min-width: 13.5rem;
    padding: 0.82rem 0.95rem;
    border: 1px solid color-mix(in srgb, var(--color-heading-accent) 34%, var(--surface-border));
    border-radius: 18px;
    background: color-mix(in srgb, var(--surface-elevated) 84%, var(--color-heading-accent) 16%);
    color: var(--color-text);
    box-shadow: var(--shadow-card);
    cursor: pointer;
    text-align: left;
    transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.dashboard-header-actions {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    align-items: stretch;
}

.dashboard-delete-offer-button {
    width: 100%;
}

.dashboard-offer-message {
    margin: -0.35rem 0 1.15rem;
    padding: 0.85rem 1rem;
    border: 1px solid rgba(220, 38, 38, 0.22);
    border-radius: 16px;
    background: rgba(220, 38, 38, 0.08);
    color: var(--color-text);
    font-weight: 650;
    text-align: left;
}

.dashboard-quick-action span,
.dashboard-quick-action small {
    display: block;
}

.dashboard-quick-action span {
    font-weight: 800;
}

.dashboard-quick-action small {
    margin-top: 0.18rem;
    color: var(--color-text-soft);
    font-weight: 600;
}

.dashboard-quick-action:hover,
.dashboard-quick-action:focus-visible {
    transform: translateY(-2px);
    box-shadow: var(--shadow-card-hover);
    filter: saturate(1.05);
    outline: none;
}

.dashboard-summary-grid {
    display: grid;
    grid-template-columns: minmax(230px, 0.38fr) minmax(0, 0.62fr);
    gap: 1rem;
    margin-bottom: 1rem;
    align-items: stretch;
}

.dashboard-summary-stack {
    display: grid;
    grid-template-rows: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.dashboard-summary-card,
.dashboard-panel {
    border: 1px solid var(--surface-border);
    background: var(--surface-card);
    box-shadow: var(--shadow-card);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.dashboard-summary-card {
    position: relative;
    min-height: 150px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 1rem;
    border-radius: 18px;
    overflow: hidden;
    animation: dashboard-rise 0.42s ease both;
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

a.dashboard-summary-card {
    color: inherit;
    text-decoration: none;
}

.dashboard-summary-card-requests {
    animation-delay: 0.02s;
}

.dashboard-summary-card-completed {
    animation-delay: 0.08s;
}

.dashboard-summary-card-revenue {
    animation-delay: 0.14s;
}

.dashboard-summary-card::before {
    content: "";
    position: absolute;
    inset: auto 1rem 0.85rem 1rem;
    height: 3px;
    border-radius: 999px;
    background: var(--dashboard-tone, rgba(172, 142, 255, 0.72));
    animation: dashboard-line-reveal 0.48s ease both;
    animation-delay: inherit;
    transform-origin: left center;
}

.dashboard-summary-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-card-hover);
}

.dashboard-summary-card-requests {
    --dashboard-tone: #f59e0b;
}

.dashboard-summary-card-completed {
    --dashboard-tone: #22c55e;
}

.dashboard-summary-card-revenue {
    --dashboard-tone: #38bdf8;
}

.dashboard-summary-label,
.dashboard-summary-meta {
    color: var(--color-text-soft);
    font-size: 0.82rem;
    font-weight: 700;
}

.dashboard-summary-label {
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.dashboard-summary-value {
    color: var(--color-text);
    font-size: clamp(2.2rem, 5vw, 3.4rem);
    line-height: 1;
    letter-spacing: -0.05em;
}

.dashboard-subject-panel {
    min-height: 316px;
    display: flex;
    flex-direction: column;
    gap: 1.15rem;
    padding: 1.1rem;
    border: 1px solid var(--surface-border);
    border-radius: 22px;
    background: var(--surface-card);
    box-shadow: var(--shadow-card);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    animation: dashboard-rise 0.42s ease 0.14s both;
}

.dashboard-subject-heading {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
}

.dashboard-subject-heading h2 {
    margin: 0;
    font-size: clamp(1.25rem, 2.5vw, 1.55rem);
}

.dashboard-subject-content {
    flex: 1;
    display: grid;
    grid-template-columns: minmax(180px, 0.95fr) minmax(180px, 1.05fr);
    gap: 1.25rem;
    align-items: center;
}

.dashboard-subject-donut-wrap {
    position: relative;
    width: min(100%, 260px);
    aspect-ratio: 1;
    justify-self: center;
    display: grid;
    place-items: center;
}

.dashboard-subject-donut {
    width: 100%;
    height: 100%;
    overflow: visible;
    transform: rotate(-90deg);
}

.dashboard-subject-total {
    position: absolute;
    inset: 50% auto auto 50%;
    transform: translate(-50%, -50%);
    color: var(--color-heading-accent);
    font-size: clamp(1.45rem, 3vw, 2.2rem);
    font-weight: 900;
    line-height: 1;
    white-space: nowrap;
}

.dashboard-subject-donut-base,
.dashboard-subject-donut-segment,
.dashboard-subject-donut-mask {
    fill: none;
    stroke-width: 8;
}

.dashboard-subject-donut-base {
    stroke: color-mix(in srgb, var(--surface-hover) 58%, transparent);
}

.dashboard-subject-donut-segment {
    stroke-linecap: butt;
    transition: stroke-dasharray 0.28s ease, stroke-dashoffset 0.28s ease;
}

.dashboard-subject-donut-mask {
    stroke: #fff;
    stroke-linecap: butt;
    stroke-dasharray: 0 100;
    animation: dashboard-donut-sweep 0.82s cubic-bezier(0.2, 0.8, 0.2, 1) 0.18s both;
}

.dashboard-subject-legend {
    display: grid;
    gap: 0.65rem;
}

.dashboard-subject-legend-item {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 0.65rem;
    align-items: center;
    padding: 0.68rem 0.75rem;
    border: 1px solid var(--surface-border);
    border-radius: 14px;
    background: color-mix(in srgb, var(--surface-panel) 72%, transparent);
    color: var(--color-text-muted);
    font-weight: 700;
    animation: dashboard-list-rise 0.38s ease both;
    animation-delay: var(--legend-delay, 0.28s);
}

.dashboard-subject-legend-item strong {
    color: var(--color-text);
}

.dashboard-subject-color {
    width: 0.78rem;
    height: 0.78rem;
    border-radius: 999px;
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.04);
}

.dashboard-tone-success {
    --dashboard-tone: #22c55e;
}

.dashboard-tone-info {
    --dashboard-tone: #38bdf8;
}

.dashboard-tone-warning {
    --dashboard-tone: #f59e0b;
}

.dashboard-tone-neutral {
    --dashboard-tone: var(--color-heading-accent);
}

.dashboard-chart-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.dashboard-panel {
    border-radius: 22px;
    padding: 1.1rem;
    animation: dashboard-rise 0.42s ease both;
}

.dashboard-chart-panel {
    animation-delay: 0.2s;
}

.dashboard-request-panel {
    animation-delay: 0.26s;
}

.dashboard-activity-panel {
    animation-delay: 0.32s;
}

.dashboard-panel-heading {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.dashboard-panel-heading h2 {
    margin: 0;
    font-size: clamp(1.25rem, 2.5vw, 1.55rem);
}

.dashboard-chart-heading-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: center;
    gap: 0.45rem;
}

.dashboard-chart-total,
.dashboard-count-badge,
.dashboard-chart-period,
.dashboard-live-indicator {
    flex-shrink: 0;
    padding: 0.42rem 0.7rem;
    border: 1px solid var(--surface-border);
    border-radius: 999px;
    background: var(--surface-badge);
    color: var(--color-heading-accent);
    font-size: 0.8rem;
    font-weight: 800;
}

a.dashboard-count-badge {
    text-decoration: none;
    transition: transform 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

a.dashboard-count-badge:hover,
a.dashboard-count-badge:focus-visible {
    transform: translateY(-1px);
    background: var(--surface-hover);
    border-color: var(--surface-border-strong);
    outline: none;
}

.dashboard-chart-period {
    min-width: 4.6rem;
    text-align: center;
    background: var(--surface-elevated);
    color: var(--color-text);
}

.dashboard-chart-nav-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.15rem;
    height: 2.15rem;
    border: 1px solid var(--surface-border);
    border-radius: 999px;
    background: var(--surface-elevated);
    color: var(--color-text);
    font: inherit;
    font-weight: 900;
    line-height: 1;
    cursor: pointer;
    transition: transform 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

.dashboard-chart-nav-button:hover,
.dashboard-chart-nav-button:focus-visible {
    transform: translateY(-1px);
    background: var(--surface-hover);
    border-color: var(--surface-border-strong);
    outline: none;
}

.dashboard-chart {
    min-height: 300px;
    display: grid;
    grid-template-columns: repeat(12, minmax(44px, 1fr));
    gap: clamp(0.75rem, 2vw, 1.2rem);
    align-items: end;
    padding: 0.5rem clamp(0rem, 3vw, 1.8rem) 0;
    overflow-x: auto;
    scrollbar-width: thin;
}

.dashboard-chart-column {
    min-width: 0;
    display: grid;
    grid-template-rows: auto 1fr auto;
    gap: 0.45rem;
    align-items: end;
    height: 100%;
}

.dashboard-chart-track {
    position: relative;
    height: 225px;
    display: block;
    overflow: hidden;
    border: 1px solid var(--surface-border-strong);
    border-radius: 999px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.16), transparent 42%),
        color-mix(in srgb, var(--surface-hover) 58%, transparent);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.dashboard-chart-bar {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    display: block;
    width: 100%;
    height: var(--fill, 0%);
    min-height: 0;
    border-radius: inherit;
    background:
        radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.14), transparent 24%),
        linear-gradient(180deg, rgba(172, 142, 255, 0.9) 0%, rgba(124, 105, 205, 0.84) 48%, rgba(79, 70, 149, 0.88) 100%);
    box-shadow:
        0 -10px 26px rgba(124, 105, 205, 0.16),
        inset 0 1px 0 rgba(255, 255, 255, 0.24);
    animation: dashboard-bar-grow 0.72s cubic-bezier(0.2, 0.8, 0.2, 1) both;
    transform-origin: bottom;
    transition: height 0.52s cubic-bezier(0.2, 0.8, 0.2, 1), min-height 0.52s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.dashboard-chart-column-empty .dashboard-chart-track {
    opacity: 0.42;
}

.dashboard-chart-column-empty .dashboard-chart-bar {
    display: none;
}

.dashboard-chart-column-empty .dashboard-chart-value,
.dashboard-chart-column-empty .dashboard-chart-label {
    color: var(--color-text-soft);
    opacity: 0.72;
}

.dashboard-chart-value,
.dashboard-chart-label {
    display: block;
    color: var(--color-text-soft);
    font-size: 0.78rem;
    font-weight: 800;
    text-align: center;
    white-space: nowrap;
}

.dashboard-chart-value {
    color: var(--color-text-muted);
}

.dashboard-work-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(290px, 0.75fr);
    gap: 1rem;
    align-items: start;
}

.dashboard-request-list,
.dashboard-activity-list {
    display: grid;
    gap: 0.75rem;
}

.dashboard-request-item {
    display: grid;
    grid-template-columns: minmax(190px, 1fr) minmax(7.5rem, auto) auto;
    gap: 1rem;
    align-items: center;
    padding: 0.85rem;
    border: 1px solid var(--surface-border);
    border-radius: 16px;
    background: color-mix(in srgb, var(--surface-panel) 72%, transparent);
    animation: dashboard-list-rise 0.38s ease both;
    transition: transform 0.16s ease, border-color 0.16s ease, background-color 0.16s ease, box-shadow 0.16s ease;
}

.dashboard-request-item:nth-child(1) {
    animation-delay: 0.34s;
}

.dashboard-request-item:nth-child(2) {
    animation-delay: 0.42s;
}

.dashboard-request-item:nth-child(3) {
    animation-delay: 0.5s;
}

.dashboard-request-item:nth-child(4) {
    animation-delay: 0.58s;
}

.dashboard-request-item:hover {
    transform: translateY(-1px);
    border-color: color-mix(in srgb, var(--color-heading-accent) 36%, var(--surface-border));
    box-shadow: var(--shadow-card);
}

.dashboard-request-outgoing {
    border-color: color-mix(in srgb, #38bdf8 34%, var(--surface-border));
}

.dashboard-request-accepted {
    border-color: rgba(34, 197, 94, 0.36);
}

.dashboard-request-declined {
    border-color: rgba(245, 158, 11, 0.4);
}

.dashboard-request-main,
.dashboard-request-meta {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.dashboard-request-main strong {
    color: var(--color-text);
    font-size: 1.08rem;
    font-weight: 900;
    line-height: 1.15;
}

.dashboard-request-main span {
    color: var(--color-text-soft);
    font-size: 0.84rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.dashboard-request-direction,
.dashboard-request-status {
    display: inline-flex;
    width: fit-content;
    align-items: center;
    border: 1px solid var(--surface-border);
    border-radius: 999px;
    background: var(--surface-badge);
    color: var(--color-text-muted);
    font-size: 0.74rem;
    font-weight: 800;
    line-height: 1.1;
}

.dashboard-request-direction {
    margin-top: 0.12rem;
    padding: 0.26rem 0.5rem;
}

.dashboard-request-status {
    align-self: flex-end;
    padding: 0.24rem 0.48rem;
}

.dashboard-request-outgoing .dashboard-request-direction {
    border-color: rgba(56, 189, 248, 0.34);
    color: #0284c7;
}

.dashboard-request-accepted .dashboard-request-status {
    border-color: rgba(34, 197, 94, 0.36);
    color: #16a34a;
}

.dashboard-request-declined .dashboard-request-status {
    border-color: rgba(245, 158, 11, 0.38);
    color: #d97706;
}

.dashboard-request-meta {
    color: var(--color-text-soft);
    font-size: 0.84rem;
    font-weight: 700;
}

.dashboard-request-meta {
    text-align: right;
}

.dashboard-request-price {
    color: var(--color-text);
    font-size: 0.96rem;
    font-weight: 900;
}

.dashboard-request-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    justify-content: flex-end;
}

.dashboard-action-button {
    min-height: 38px;
    padding: 0.55rem 0.75rem;
    border: 1px solid var(--surface-border);
    border-radius: 999px;
    background: var(--surface-elevated);
    color: var(--color-text);
    font: inherit;
    font-size: 0.86rem;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

.dashboard-action-button:hover,
.dashboard-action-button:focus-visible {
    transform: translateY(-1px);
    outline: none;
}

.dashboard-action-accept {
    border-color: rgba(34, 197, 94, 0.42);
    background: linear-gradient(135deg, #16a34a, #22c55e);
    color: #ffffff;
    box-shadow: 0 10px 22px rgba(34, 197, 94, 0.2);
}

.dashboard-action-accept:hover,
.dashboard-action-accept:focus-visible {
    background: linear-gradient(135deg, #15803d, #16a34a);
}

.dashboard-action-decline {
    border-color: var(--surface-border);
    color: var(--color-text-soft);
}

.dashboard-action-decline:hover,
.dashboard-action-decline:focus-visible {
    background: color-mix(in srgb, var(--surface-hover) 78%, transparent);
    border-color: rgba(245, 158, 11, 0.34);
    color: #d97706;
}

.dashboard-action-read {
    border-color: rgba(56, 189, 248, 0.42);
    color: #0284c7;
}

.dashboard-action-read:hover,
.dashboard-action-read:focus-visible {
    background: rgba(56, 189, 248, 0.12);
    border-color: rgba(56, 189, 248, 0.58);
}

.dashboard-request-message {
    grid-column: 1 / -1;
    margin: 0.85rem 0 0;
    padding: 0.85rem 1rem;
    border: 1px solid rgba(245, 158, 11, 0.32);
    border-radius: 16px;
    background: rgba(245, 158, 11, 0.1);
    color: var(--color-text);
    font-weight: 700;
    text-align: left;
}

.dashboard-empty-inline {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding: 1rem;
    border: 1px dashed var(--surface-border-strong);
    border-radius: 16px;
    background: var(--surface-empty);
    color: var(--color-text-muted);
    animation: dashboard-list-rise 0.38s ease 0.34s both;
}

.dashboard-empty-inline strong {
    color: var(--color-text);
}

.dashboard-empty-inline span {
    color: var(--color-text-soft);
}

.dashboard-live-indicator {
    position: relative;
    padding-left: 1.55rem;
}

.dashboard-live-indicator::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 0.72rem;
    width: 0.45rem;
    height: 0.45rem;
    border-radius: 999px;
    background: #22c55e;
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.45);
    transform: translateY(-50%);
    animation: dashboard-pulse 1.8s ease-out infinite;
}

.dashboard-activity-item {
    position: relative;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0.75rem;
    padding: 0.75rem 0.8rem;
    border-radius: 16px;
    background: color-mix(in srgb, var(--surface-panel) 70%, transparent);
    animation: dashboard-list-rise 0.38s ease both;
    transition: transform 0.16s ease, background-color 0.16s ease;
}

.dashboard-activity-item:hover {
    transform: translateY(-1px);
    background: color-mix(in srgb, var(--surface-panel) 86%, transparent);
}

.dashboard-activity-item:nth-child(1) {
    animation-delay: 0.4s;
}

.dashboard-activity-item:nth-child(2) {
    animation-delay: 0.48s;
}

.dashboard-activity-item:nth-child(3) {
    animation-delay: 0.56s;
}

.dashboard-activity-item:nth-child(4) {
    animation-delay: 0.64s;
}

.dashboard-activity-item:nth-child(5) {
    animation-delay: 0.72s;
}

.dashboard-activity-item:nth-child(6) {
    animation-delay: 0.8s;
}

.dashboard-activity-dot {
    width: 0.72rem;
    height: 0.72rem;
    margin-top: 0.34rem;
    border-radius: 999px;
    background: var(--dashboard-tone, var(--color-heading-accent));
    box-shadow: 0 0 0 5px color-mix(in srgb, var(--dashboard-tone, var(--color-heading-accent)) 14%, transparent);
}

.dashboard-activity-item strong,
.dashboard-activity-item p,
.dashboard-activity-item time {
    display: block;
}

.dashboard-activity-item strong {
    color: var(--color-text);
}

.dashboard-activity-item p {
    margin: 0.08rem 0 0;
    color: var(--color-text-muted);
    line-height: 1.35;
}

.dashboard-activity-item time {
    margin-top: 0.3rem;
    color: var(--color-text-soft);
    font-size: 0.8rem;
    font-weight: 700;
}

[data-theme="dark"] .dashboard-summary-card,
[data-theme="dark"] .dashboard-subject-panel,
[data-theme="dark"] .dashboard-panel {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent),
        var(--surface-card);
}

[data-theme="dark"] .dashboard-action-accept {
    color: #ffffff;
}

[data-theme="dark"] .dashboard-action-decline {
    color: #fbbf24;
}

@keyframes dashboard-rise {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes dashboard-bar-grow {
    from {
        transform: scaleY(0);
    }

    to {
        transform: scaleY(1);
    }
}

@keyframes dashboard-donut-sweep {
    from {
        opacity: 0;
        stroke-dasharray: 0 100;
    }

    2% {
        opacity: 1;
        stroke-dasharray: 0 100;
    }

    to {
        opacity: 1;
        stroke-dasharray: 100.5 100;
    }
}

@keyframes dashboard-list-rise {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes dashboard-line-reveal {
    from {
        transform: scaleX(0);
    }

    to {
        transform: scaleX(1);
    }
}

@keyframes dashboard-pulse {
    70% {
        box-shadow: 0 0 0 9px rgba(34, 197, 94, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .dashboard-summary-card,
    .dashboard-subject-panel,
    .dashboard-panel,
    .dashboard-subject-donut-mask,
    .dashboard-subject-legend-item,
    .dashboard-request-item,
    .dashboard-activity-item,
    .dashboard-empty-inline,
    .dashboard-chart-bar,
    .dashboard-live-indicator::before {
        animation: none;
    }

    .dashboard-subject-donut-mask {
        opacity: 1;
        stroke-dasharray: 100.5 100;
    }
}

@media (max-width: 1040px) {
    .dashboard-summary-grid,
    .dashboard-work-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-summary-stack {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        grid-template-rows: none;
    }
}

@media (max-width: 760px) {
    .dashboard-header,
    .dashboard-chart-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-quick-action {
        width: 100%;
    }

    .dashboard-header-actions {
        width: 100%;
    }

    .dashboard-subject-content {
        grid-template-columns: 1fr;
    }

    .dashboard-summary-stack {
        grid-template-columns: 1fr;
    }

    .dashboard-request-item {
        grid-template-columns: 1fr;
    }

    .dashboard-request-meta {
        text-align: left;
    }

    .dashboard-request-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 480px) {
    .dashboard-summary-stack {
        grid-template-columns: 1fr;
    }

    .dashboard-panel,
    .dashboard-summary-card,
    .dashboard-subject-panel {
        border-radius: 16px;
    }

    .dashboard-chart {
        gap: 0.45rem;
        grid-template-columns: repeat(12, minmax(38px, 1fr));
    }

    .dashboard-chart-value {
        display: none;
    }
}

/* ============================= */
/* Responsive */
/* ============================= */

@media (max-width: 900px) {
    .why-section {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 1.6rem;
    }

    .why-right {
        text-align: center;
    }

    .why-head {
        justify-content: center;
        gap: 1rem;
    }

    .why-left img {
        max-width: 500px;
    }
}

@media (max-width: 768px) {
    .hero-buttons {
        gap: 0.9rem;
    }

    .btn-primary-custom,
    .btn-secondary-custom {
        width: min(360px, 100%);
        text-align: center;
    }

    .home-image {
        margin-top: 2rem;
        border-radius: 14px;
    }

    .profile-hero,
    .profile-grid,
    .offer-form-layout,
    .profile-info-grid {
        grid-template-columns: 1fr;
    }

    .profile-hero-main {
        grid-template-columns: 132px minmax(0, 1fr);
    }

    .profile-avatar-shell {
        width: 100%;
        min-height: 132px;
    }

    .profile-avatar-shell.is-empty {
        width: 132px;
        min-height: auto;
    }

    .profile-info-item-wide {
        grid-column: auto;
    }

    .tutor-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .results-summary {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        flex-wrap: nowrap;
    }

}

@media (max-width: 640px) {
    .offer-form-header,
    .profile-detail-header {
        flex-direction: column;
    }

    .profile-page {
        margin-top: 1rem;
    }

    .profile-hero {
        padding: 1rem;
        border-radius: 22px;
    }

    .profile-hero-main {
        grid-template-columns: 1fr;
    }

    .profile-avatar-shell {
        width: min(168px, 52vw);
        min-height: auto;
        aspect-ratio: 1;
    }

    .profile-hero-copy h1 {
        max-width: none;
        font-size: clamp(2rem, 12vw, 3rem);
    }

    .profile-detail-panel,
    .profile-tutor-panel,
    .profile-state-card,
    .auth-shell {
        padding: 1.05rem;
        border-radius: 20px;
    }

    .profile-tutor-metrics {
        grid-template-columns: 1fr;
    }

    .subject-selection-input-row {
        flex-direction: column;
    }

    .offer-form-actions {
        justify-content: stretch;
    }

    .offer-form-actions .btn-primary-custom {
        width: 100%;
        text-align: center;
    }

    .auth-actions {
        justify-content: stretch;
    }

    .auth-actions .btn-primary-custom,
    .auth-actions .btn-secondary-custom {
        width: 100%;
    }

    .profile-upload-box {
        align-items: flex-start;
        flex-direction: column;
    }

    .registration-image-step {
        align-items: stretch;
        flex-direction: column;
    }

    .registration-avatar-shell {
        width: min(260px, 100%);
    }

    .image-crop-frame {
        width: min(260px, 100%);
        height: auto;
        aspect-ratio: 1;
    }

    .crop-controls {
        grid-template-columns: 1fr;
    }

    .tutoring-header p {
        margin-bottom: 1.2rem;
    }

    .tutoring-header-with-action {
        align-items: flex-start;
        justify-content: space-between;
    }

    .tutoring-header-with-action .tutor-add-button {
        position: static;
    }

    .tutor-add-button {
        width: 2.75rem;
        height: 2.75rem;
        font-size: 1.55rem;
    }

    .tutor-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .filter-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .results-summary {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        flex-wrap: nowrap;
    }

    .results-sort {
        margin-left: auto;
    }

    .tutor-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.9rem;
    }

    .tutor-image {
        height: 210px;
    }

    .tutor-topline {
        flex-direction: column;
    }

    .tutor-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.45rem;
    }

    .tutor-modal-overlay {
        padding: 1rem;
    }

    .tutor-modal {
        padding: 1rem;
        border-radius: 22px;
    }

    .tutor-modal-header {
        flex-direction: column;
        gap: 1rem;
        padding-right: 2.75rem;
    }

    .tutor-modal-image {
        width: 100%;
        height: 230px;
    }

    .tutor-edit-modal {
        padding: 1rem 1rem 1.15rem;
        padding-top: 1rem;
        padding-bottom: calc(7.25rem + env(safe-area-inset-bottom, 0px));
    }

    .tutor-edit-modal .tutor-edit-button-modal,
    .tutor-edit-modal .tutor-modal-close {
        width: 2.5rem;
        height: 2.5rem;
    }

    .tutor-edit-modal .tutor-edit-button-modal {
        display: none;
    }

    .tutor-edit-modal .tutor-edit-button-modal {
        right: 3.9rem;
    }

    .tutor-edit-modal .tutor-modal-close {
        top: 1.7rem;
        right: 1.35rem;
        z-index: 3;
        background: rgba(255, 255, 255, 0.78);
        backdrop-filter: blur(8px);
        border-color: rgba(255, 255, 255, 0.72);
        box-shadow: 0 10px 22px rgba(15, 23, 42, 0.18);
    }

    .tutor-edit-modal .tutor-modal-header {
        gap: 1.15rem;
        padding-right: 0;
        padding-bottom: 1rem;
        margin-bottom: 1.15rem;
    }

    .tutor-edit-modal .tutor-modal-image {
        height: 142px;
        min-height: 142px;
        border-radius: 20px;
        padding-right: 3.5rem;
    }

    .tutor-edit-modal .tutor-modal-header-content {
        gap: 0.8rem;
        padding: 0;
    }

    .tutor-edit-modal .tutor-modal-intro {
        gap: 0.5rem;
    }

    .tutor-edit-form,
    .tutor-edit-form .tutor-modal-body,
    .tutor-edit-form .offer-form-layout {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }

    .tutor-edit-form .tutor-modal-section {
        width: 100%;
    }

    .tutor-edit-form .offer-form-field,
    .tutor-edit-form .offer-form-input-prefix-wrap,
    .tutor-edit-form .subject-selection-input-row,
    .tutor-edit-form .subject-selection-add-button {
        width: 100%;
    }

    .tutor-edit-form .subject-selection-input-row {
        gap: 0.7rem;
    }

    .tutor-edit-form .subject-selection-add-button {
        justify-content: center;
    }

    .tutor-edit-validation {
        padding-left: 0;
    }

    .tutor-edit-mobile-actions {
        position: fixed;
        left: 1rem;
        right: 1rem;
        bottom: calc(1.25rem + env(safe-area-inset-bottom, 0px));
        z-index: 1250;
        display: block;
        pointer-events: none;
    }

    .tutor-edit-mobile-save {
        pointer-events: auto;
        box-shadow: 0 18px 32px rgba(34, 197, 94, 0.26);
    }

    .tutor-modal-highlights,
    .tutor-secondary-grid,
    .tutor-modal-details {
        grid-template-columns: 1fr;
    }

    .tutor-section-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .tutor-modal-cta {
        justify-content: stretch;
    }

    .tutor-request-button {
        width: 100%;
    }

    .tutor-request-hint {
        text-align: left;
    }

}

@media (max-width: 480px) {
    .tutor-filters {
        grid-template-columns: 1fr;
    }

    h1 {
        letter-spacing: -0.5px;
    }

    h2 {
        font-size: 1.6rem;
    }

    .trustbar {
        height: auto;
    }

    .why-head h3 {
        font-size: 1.1rem;
    }
}
