:root {
    --bg: #f3efe7;
    --bg-alt: #fbf8f2;
    --panel: rgba(255, 252, 246, 0.88);
    --panel-strong: #fffdf8;
    --text: #15211d;
    --muted: #5b6b65;
    --line: rgba(21, 33, 29, 0.1);
    --accent: #0f766e;
    --accent-strong: #0b5d57;
    --accent-soft: #d9f3ef;
    --warm: #c56a2d;
    --danger: #b42318;
    --success: #027a48;
    --shadow: 0 20px 60px rgba(41, 52, 46, 0.12);
    --radius-xl: 32px;
    --radius-lg: 24px;
    --radius-md: 18px;
    --radius-sm: 12px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: 'Manrope', sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(15, 118, 110, 0.14), transparent 24%),
        radial-gradient(circle at right 20%, rgba(197, 106, 45, 0.16), transparent 18%),
        linear-gradient(180deg, #f6f1e7 0%, #f7f5f0 100%);
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
}

.public-body,
.login-body,
.admin-body {
    min-height: 100vh;
}

.site-header,
.detail-wrap,
.hero,
.feature-band,
.section-heading,
.property-grid {
    width: min(1180px, calc(100% - 32px));
    margin-inline: auto;
}

.site-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 0 10px;
}

.site-header--compact {
    padding-bottom: 24px;
}

.brand-mark {
    display: inline-flex;
    align-items: center;
    gap: 14px;
}

.brand-mark strong,
.brand-mark small {
    display: block;
}

.brand-mark small {
    color: var(--muted);
}

.brand-mark__logo {
    width: 46px;
    height: 46px;
    display: inline-grid;
    place-items: center;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--accent), #123b35);
    color: white;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.top-nav,
.admin-nav {
    display: flex;
    gap: 18px;
    align-items: center;
}

.top-nav a,
.admin-nav a,
.text-link {
    color: var(--muted);
    font-weight: 700;
}

.top-nav a:hover,
.admin-nav a:hover,
.text-link:hover {
    color: var(--accent);
}

.hero {
    display: grid;
    grid-template-columns: 1.25fr 0.85fr;
    gap: 28px;
    align-items: stretch;
    padding: 28px 0 44px;
}

.hero__content,
.hero__panel,
.search-panel,
.admin-card,
.metric-card,
.contact-card,
.empty-state {
    background: var(--panel);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.45);
    box-shadow: var(--shadow);
}

.hero__content {
    border-radius: var(--radius-xl);
    padding: 42px;
}

.hero__panel {
    border-radius: var(--radius-xl);
    padding: 20px;
}

.eyebrow {
    display: inline-flex;
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(15, 118, 110, 0.1);
    color: var(--accent-strong);
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

h1,
h2,
h3 {
    margin: 0;
    font-family: 'Fraunces', serif;
    line-height: 1.05;
}

.hero h1 {
    font-size: clamp(2.8rem, 5vw, 4.8rem);
    margin: 18px 0 18px;
    max-width: 10.5ch;
}

.hero p,
.property-card p,
.admin-card p,
.detail-description p {
    color: var(--muted);
    line-height: 1.7;
}

.hero__cta {
    display: flex;
    gap: 12px;
    margin: 28px 0;
}

.button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    min-height: 48px;
    padding: 0 18px;
    border: none;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 800;
    font-size: 0.95rem;
}

.button--primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    color: white;
}

.button--ghost {
    background: rgba(255, 255, 255, 0.66);
    color: var(--text);
    border: 1px solid var(--line);
}

.button--full {
    width: 100%;
}

.button--compact {
    min-height: 42px;
    padding: 0 15px;
    font-size: 0.88rem;
}

.stats-strip {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin: 0;
}

.stats-strip div,
.property-card__stats div {
    padding: 16px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.54);
    border: 1px solid rgba(21, 33, 29, 0.08);
}

.stats-strip dt,
.property-card__stats dt {
    margin-bottom: 6px;
    color: var(--muted);
    font-size: 0.8rem;
}

.stats-strip dd,
.property-card__stats dd {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 800;
}

.search-panel {
    border-radius: calc(var(--radius-xl) - 6px);
    padding: 18px;
}

.search-panel__header,
.active-filters__head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 16px;
}

.search-panel__header h2 {
    font-size: 1.7rem;
    margin-bottom: 6px;
}

.search-panel__header p {
    margin: 0;
}

.search-panel__clear {
    padding-top: 10px;
}

.search-grid,
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.search-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

label {
    display: grid;
    gap: 8px;
    color: var(--muted);
    font-weight: 700;
}

input,
select,
textarea {
    width: 100%;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.8);
    font: inherit;
    color: var(--text);
}

textarea {
    resize: vertical;
}

.alert {
    padding: 14px 16px;
    border-radius: 16px;
    font-weight: 700;
}

.alert--danger {
    background: rgba(180, 35, 24, 0.09);
    color: var(--danger);
}

.alert--success {
    background: rgba(2, 122, 72, 0.1);
    color: var(--success);
}

.alert--neutral {
    background: rgba(21, 33, 29, 0.06);
    color: var(--text);
}

.feature-band {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-bottom: 28px;
}

.value-strip,
.process-grid {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 28px;
    display: grid;
    gap: 20px;
}

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

.process-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding-bottom: 56px;
}

.feature-band article {
    padding: 24px;
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.58);
    border: 1px solid var(--line);
}

.value-card,
.process-card {
    padding: 28px;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.62);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.process-card strong {
    display: inline-grid;
    place-items: center;
    width: 54px;
    height: 54px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    color: #fff;
    font-size: 1.1rem;
    margin-bottom: 16px;
}

.feature-band h3 {
    margin-bottom: 12px;
}

.section-heading {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 16px;
    margin-bottom: 18px;
}

.catalog-strip {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 26px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.catalog-strip__item {
    padding: 20px 22px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(21, 33, 29, 0.08);
    box-shadow: var(--shadow);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.catalog-strip__item:hover {
    transform: translateY(-3px);
    box-shadow: 0 24px 54px rgba(41, 52, 46, 0.16);
}

.catalog-strip__item strong,
.search-panel__shortcut-label {
    display: block;
    margin-bottom: 6px;
    font-weight: 800;
}

.catalog-strip__item span {
    color: var(--muted);
    line-height: 1.5;
}

.section-heading h2 {
    font-size: clamp(2rem, 3vw, 3rem);
    margin-top: 8px;
}

.section-heading--stacked {
    align-items: flex-start;
}

.property-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
    padding-bottom: 56px;
}

.property-card {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.74);
    border: 1px solid rgba(21, 33, 29, 0.08);
    box-shadow: var(--shadow);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.property-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 24px 54px rgba(41, 52, 46, 0.16);
}

.property-card--inactive {
    background: rgba(245, 245, 245, 0.84);
    border-color: rgba(21, 33, 29, 0.12);
    opacity: 0.74;
}

.property-card--inactive:hover {
    transform: none;
    box-shadow: var(--shadow);
}

.property-card--inactive .property-card__media,
.property-card--inactive .property-card__body {
    filter: grayscale(1) saturate(0.05);
}

.property-card--inactive::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.18);
    pointer-events: none;
    z-index: 2;
}

.property-card__media {
    position: relative;
    min-height: 260px;
    background-size: cover;
    background-position: center;
}

.property-card__media::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15, 33, 29, 0.02) 15%, rgba(15, 33, 29, 0.7) 100%);
}

.property-card__badge {
    position: absolute;
    top: 18px;
    left: 18px;
    padding: 9px 12px;
    border-radius: 999px;
    background: rgba(21, 33, 29, 0.8);
    color: white;
    font-size: 0.82rem;
    font-weight: 800;
    z-index: 1;
}

.property-card__ribbon {
    position: absolute;
    top: 24px;
    right: -56px;
    z-index: 3;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 220px;
    height: 36px;
    transform: rotate(42deg);
    background: rgba(62, 62, 62, 0.95);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
    pointer-events: none;
}

.property-card__price {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    max-width: 100%;
    padding: 10px 14px;
    border-radius: 16px;
    background: rgba(21, 33, 29, 0.82);
    backdrop-filter: blur(10px);
    font-size: 1.08rem;
    font-weight: 800;
    line-height: 1.1;
    text-align: center;
    white-space: nowrap;
}

.property-card__body {
    padding: 22px;
}

.property-card__meta,
.table-header {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
}

.property-card__meta {
    color: var(--muted);
    font-size: 0.88rem;
    margin-bottom: 10px;
}

.property-card h3 {
    font-size: 1.08rem;
    margin-bottom: 8px;
    line-height: 1.2;
    min-height: 2.4em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.property-card__summary {
    margin: 0;
    color: var(--muted);
    font-size: 0.95rem;
    line-height: 1.5;
}

.property-card__description {
    margin: 12px 0 0;
    color: var(--muted);
    line-height: 1.65;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.property-card__chips {
    margin-top: 14px;
}

.property-card__stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin: 18px 0;
}

.property-card__stats--detail {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.property-card__footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.property-card__footer-price {
    display: inline-flex;
    align-items: center;
    min-height: 56px;
    padding: 0 20px;
    border-radius: 20px;
    background: linear-gradient(135deg, #0c5f58, #0f766e);
    color: #fff;
    font-size: 1.55rem;
    font-weight: 800;
    line-height: 1.15;
    box-shadow: 0 18px 34px rgba(15, 118, 110, 0.28);
    white-space: nowrap;
}

.property-card__footer .button--ghost {
    background: rgba(255, 255, 255, 0.55);
    color: var(--text);
    border-color: rgba(21, 33, 29, 0.1);
    min-height: 46px;
    padding-inline: 16px;
    font-size: 0.9rem;
}

.property-card__footer strong,
.detail-price {
    font-size: 1.35rem;
}

.search-panel__shortcuts {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--line);
}

.filter-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.filter-pill {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 0 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(21, 33, 29, 0.08);
    color: var(--text);
    font-weight: 700;
}

.filter-pill--active,
.filter-pill:hover {
    background: var(--accent-soft);
    color: var(--accent-strong);
}

.active-filters {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 24px;
    padding: 20px 22px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.66);
    border: 1px solid rgba(21, 33, 29, 0.08);
    box-shadow: var(--shadow);
}

.empty-state {
    padding: 32px;
    border-radius: var(--radius-lg);
    grid-column: 1 / -1;
}

.empty-state--spacious {
    width: min(900px, calc(100% - 32px));
    margin: 40px auto;
}

.detail-wrap {
    padding-bottom: 56px;
}

.auth-shell {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 24px;
    align-items: stretch;
}

.auth-shell--reverse {
    grid-template-columns: 0.95fr 1.05fr;
}

.auth-hero,
.auth-panel {
    min-height: 100%;
}

.auth-hero {
    padding: 34px;
    border-radius: var(--radius-xl);
    background: rgba(255, 252, 246, 0.82);
    border: 1px solid rgba(255, 255, 255, 0.45);
    box-shadow: var(--shadow);
}

.auth-hero h1 {
    margin: 16px 0 14px;
    font-size: clamp(2.3rem, 4vw, 3.6rem);
    max-width: 11ch;
}

.auth-hero p {
    margin: 0;
    color: var(--muted);
    line-height: 1.7;
}

.auth-points {
    display: grid;
    gap: 14px;
    margin-top: 24px;
}

.auth-points__item {
    padding: 18px 20px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.62);
    border: 1px solid rgba(21, 33, 29, 0.08);
}

.auth-points__item strong {
    display: block;
    margin-bottom: 6px;
    font-size: 1rem;
}

.auth-points__item span,
.auth-panel__lead,
.auth-panel__footer span,
.account-heading p,
.account-summary p {
    color: var(--muted);
    line-height: 1.6;
}

.auth-panel__lead {
    margin: 8px 0 18px;
}

.auth-panel__footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid var(--line);
}

.account-heading {
    margin-top: 4px;
}

.account-heading h1 {
    font-size: clamp(2rem, 3vw, 3rem);
    margin-top: 8px;
}

.account-heading p {
    max-width: 54ch;
    margin: 0;
}

.account-summary {
    display: grid;
    gap: 16px;
}

.detail-hero {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 24px;
    margin-bottom: 24px;
}

.detail-hero__image,
.gallery-grid__item {
    min-height: 520px;
    border-radius: var(--radius-xl);
    background-size: cover;
    background-position: center;
    box-shadow: var(--shadow);
}

.detail-hero__panel {
    padding: 30px;
    border-radius: var(--radius-xl);
    background: rgba(255, 252, 246, 0.84);
    box-shadow: var(--shadow);
}

.detail-content {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 24px;
}

.detail-description,
.detail-sidebar {
    display: grid;
    gap: 18px;
}

.detail-description,
.contact-card {
    padding: 28px;
    border-radius: var(--radius-lg);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: 24px;
}

.gallery-grid__item {
    min-height: 240px;
}

.login-body {
    display: grid;
    place-items: center;
    padding: 24px;
}

.login-panel {
    width: min(1040px, 100%);
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 24px;
}

.login-panel--compact {
    width: min(520px, 100%);
    grid-template-columns: 1fr;
}

.login-panel__intro,
.admin-card {
    padding: 28px;
    border-radius: var(--radius-xl);
}

.credential-box,
.chip,
.user-chip {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    padding: 10px 14px;
    border-radius: 14px;
    background: var(--accent-soft);
    color: var(--accent-strong);
    font-weight: 800;
}

.admin-shell {
    display: grid;
    grid-template-columns: 260px 1fr;
    min-height: 100vh;
}

.admin-sidebar {
    padding: 24px;
    border-right: 1px solid var(--line);
    background: rgba(255, 252, 246, 0.7);
}

.brand-mark--stacked {
    margin-bottom: 26px;
}

.admin-nav {
    flex-direction: column;
    align-items: stretch;
}

.admin-nav a {
    padding: 12px 14px;
    border-radius: 12px;
}

.admin-nav a:hover {
    background: rgba(15, 118, 110, 0.08);
}

.admin-main {
    padding: 24px;
}

.admin-topbar {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: center;
    margin-bottom: 20px;
}

.admin-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.admin-grid--stats {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.metric-card span {
    display: block;
    color: var(--muted);
    margin-bottom: 8px;
}

.metric-card strong {
    font-size: 2rem;
}

.table-wrap {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    padding: 14px 10px;
    text-align: left;
    border-bottom: 1px solid var(--line);
}

th {
    color: var(--muted);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.checkbox-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-top: 34px;
}

.checkbox-row input {
    width: auto;
}

.chip-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.taxonomy-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.wizard-save-form {
    margin-top: 20px;
}

.hidden-textarea {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.copilot-answer {
    color: var(--text);
    line-height: 1.75;
    white-space: normal;
}

.process-list,
.source-list {
    display: grid;
    gap: 16px;
}

.process-item,
.source-card {
    padding: 18px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.56);
    border: 1px solid rgba(21, 33, 29, 0.08);
}

.process-item strong,
.source-card h3 {
    display: block;
    margin-bottom: 8px;
    font-family: 'Fraunces', serif;
    font-size: 1.1rem;
}

.process-item p,
.source-card p {
    margin: 0 0 12px;
}

.source-card__head {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: flex-start;
    margin-bottom: 12px;
}

.source-card--compact {
    padding: 16px;
}

.action-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.action-row form {
    margin: 0;
}

.admin-details {
    margin: 18px 0;
    padding-top: 16px;
    border-top: 1px solid var(--line);
}

.admin-details summary {
    cursor: pointer;
    font-weight: 800;
    color: var(--accent-strong);
    margin-bottom: 14px;
}

pre {
    margin: 0;
    padding: 14px;
    border-radius: var(--radius-sm);
    background: rgba(21, 33, 29, 0.04);
    border: 1px solid var(--line);
    overflow: auto;
    white-space: pre-wrap;
    word-break: break-word;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.9rem;
    line-height: 1.55;
}

@media (max-width: 980px) {
    .hero,
    .auth-shell,
    .detail-hero,
    .detail-content,
    .login-panel,
    .admin-shell,
    .admin-grid,
    .admin-grid--stats,
    .feature-band,
    .value-strip,
    .process-grid,
    .taxonomy-grid,
    .catalog-strip,
    .property-grid,
    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .admin-shell {
        display: block;
    }

    .admin-sidebar {
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }
}

@media (max-width: 1120px) {
    .search-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .site-header,
    .hero__cta,
    .top-nav,
    .section-heading,
    .property-card__footer,
    .auth-panel__footer,
    .table-header,
    .search-panel__header,
    .active-filters__head {
        flex-direction: column;
        align-items: flex-start;
    }

    .hero__content,
    .hero__panel,
    .admin-card,
    .login-panel__intro {
        padding: 22px;
    }

    .hero h1 {
        max-width: none;
        font-size: 2.6rem;
    }

    .search-grid,
    .form-grid,
    .property-card__stats,
    .property-card__stats--detail,
    .stats-strip {
        grid-template-columns: 1fr;
    }

    .property-card__footer {
        flex-direction: column;
        align-items: flex-start;
    }

    .property-card__price {
        white-space: normal;
    }
}
