
:root {
  --primary-bg: #1e1e1e;
  --container-bg: #2b2b2b;
  --border-color: #444;
  --main-brand-color: #b0767e;
  --accent-color: #764b4f;
  --primary-text-color: #eed6d3;
  --secondary-text-color: #b0a1a1;
  --success-color: #86a37e;
  --danger-color: #e89ca7;
  --warning-color: #e3c4a1;
  --info-color: #a1bde3;
  --shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
  font-family: 'Roboto', sans-serif;
  background-color: var(--primary-bg);
  color: var(--primary-text-color);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

#root {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* --- App Header (Portal) --- */
.app-header {
  background-color: var(--primary-bg);
  color: var(--primary-text-color);
  padding: 1.5rem 2rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  border-bottom: 1px solid var(--border-color);
}

.app-header h1 {
  margin: 0;
  font-weight: 700;
  font-size: 2.25rem;
  letter-spacing: 1.5px;
  color: var(--main-brand-color);
}

.app-header p {
  margin: 0;
  font-weight: 300;
  font-size: 1rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  opacity: 0.9;
}

main {
  flex-grow: 1;
  padding: 2rem;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
}

/* --- Main Controls & Nav --- */
.controls-main-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.main-nav {
    display: flex;
    gap: 0.5rem;
    background-color: var(--container-bg);
    padding: 0.5rem;
    border-radius: 8px;
}

.nav-btn {
    background: transparent;
    border: none;
    color: var(--secondary-text-color);
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s;
}
.nav-btn.active, .nav-btn:hover {
    color: var(--primary-text-color);
    background-color: var(--accent-color);
}


/* --- Dashboard --- */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 1.5rem;
}

.kpi-card {
    background-color: var(--container-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem 2rem;
    box-shadow: var(--shadow);
}

.kpi-card h3 {
    color: var(--primary-text-color);
    font-weight: 500;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
}

.portfolio-stats {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.portfolio-numbers {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    flex-grow: 1;
}

.portfolio-numbers > div {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}

.kpi-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--main-brand-color);
}

.kpi-label {
    font-size: 0.9rem;
    color: var(--secondary-text-color);
}

.donut-chart {
    transform: rotate(-90deg);
}

.donut-chart-bg {
    fill: none;
    stroke: var(--primary-bg);
}

.donut-chart-fg {
    fill: none;
    stroke: var(--success-color);
    stroke-linecap: round;
    transition: stroke-dashoffset 0.5s ease;
}

.donut-chart-text {
    font-size: 1.5rem;
    font-weight: 700;
    fill: var(--primary-text-color);
    text-anchor: middle;
    dominant-baseline: middle;
    transform: rotate(90deg);
    transform-origin: 50% 50%;
}

.rent-summary {
    display: flex;
    justify-content: space-between;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}
.rent-summary-item {
    display: flex;
    flex-direction: column;
}
.rent-summary .kpi-value {
    font-size: 1.5rem;
}
.kpi-value.rent-collected {
    color: var(--success-color);
}
.kpi-value.rent-outstanding {
    color: var(--warning-color);
}

.progress-bar-container {
    height: 10px;
    width: 100%;
    background-color: var(--primary-bg);
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.progress-bar {
    height: 100%;
    background-color: var(--success-color);
    border-radius: 5px;
    transition: width 0.5s ease-in-out;
}
.kpi-card small {
    color: var(--secondary-text-color);
    font-size: 0.85rem;
}

.recent-activity-card .activity-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.activity-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.activity-item > div {
    display: flex;
    flex-direction: column;
}
.activity-item strong {
    font-weight: 500;
}
.activity-item small {
    font-size: 0.85rem;
    color: var(--secondary-text-color);
}


/* --- Controls & Header --- */
.rent-roll-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.rent-roll-header h2 {
    font-size: 1.8rem;
    font-weight: 400;
    color: var(--primary-text-color);
    flex-shrink: 0;
    line-height: 1.2;
}
.property-owner {
    font-size: 0.9rem;
    color: var(--secondary-text-color);
    margin-top: 0.25rem;
    font-weight: 300;
}

.controls {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
}

.property-selector,
.report-controls select,
.report-controls input,
.management-form select,
.management-form textarea,
.management-form input,
.modal select,
.modal textarea,
.modal input {
    font-family: 'Roboto', sans-serif;
    background-color: var(--primary-bg);
    color: var(--primary-text-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.6rem 1rem;
    font-size: 1rem;
    transition: border-color 0.2s;
    width: 100%;
    min-height: 48px;
}

.property-selector {
  cursor: pointer;
}

.property-selector:hover,
.report-controls select:hover,
.report-controls input:hover,
.management-form select:hover,
.management-form textarea:hover,
.management-form input:hover,
.modal select:hover,
.modal textarea:hover,
.modal input:hover {
    border-color: var(--main-brand-color);
}

.date-navigator {
    display: flex;
    align-items: center;
    gap: 1rem;
    background-color: var(--container-bg);
    border-radius: 8px;
    padding: 0.2rem;
    border: 1px solid var(--border-color);
}

.date-navigator button {
    background: transparent;
    border: none;
    color: var(--primary-text-color);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.2rem 0.8rem;
    border-radius: 6px;
    transition: background-color 0.2s;
}

.date-navigator button:hover {
    background-color: var(--accent-color);
}

.date-navigator span {
    font-weight: 500;
    min-width: 150px;
    text-align: center;
}


/* --- Table --- */
.table-container {
  background-color: var(--container-bg);
  border-radius: 12px;
  box-shadow: var(--shadow);
  overflow-x: auto;
  border: 1px solid var(--border-color);
}

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

th, td {
  padding: 1.25rem 1.5rem;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
  white-space: nowrap;
}

thead th {
  background-color: rgba(0,0,0,0.1);
  font-weight: 500;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--secondary-text-color);
}

tbody tr:last-child td {
  border-bottom: none;
}

tbody tr {
  transition: background-color 0.2s ease-in-out;
}

tbody tr:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

/* --- Statuses & Balances --- */
.status {
  padding: 0.3rem 0.8rem;
  border-radius: 15px;
  font-weight: 500;
  font-size: 0.85rem;
  text-align: center;
  display: inline-block;
  min-width: 110px;
}

.status-paid {
  background-color: rgba(134, 163, 126, 0.15);
  color: var(--success-color);
}
.status-unpaid {
  background-color: rgba(232, 156, 167, 0.15);
  color: var(--danger-color);
}
.status-partial-payment {
  background-color: rgba(227, 196, 161, 0.15);
  color: var(--warning-color);
}

.balance-positive {
  color: var(--danger-color);
  font-weight: 500;
}

/* --- Buttons --- */
.btn {
  font-family: 'Roboto', sans-serif;
  cursor: pointer;
  border: 1px solid transparent;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.8rem;
  transition: all 0.2s ease-in-out;
  white-space: nowrap;
  text-decoration: none;
  display: inline-block;
  text-align: center;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1rem;
    width: 100%;
}

.btn-primary {
  background-color: var(--accent-color);
  color: var(--primary-text-color);
  border-color: var(--accent-color);
}

.btn-primary:hover {
  background-color: var(--main-brand-color);
  border-color: var(--main-brand-color);
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

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

.btn-danger {
    background-color: transparent;
    color: var(--danger-color);
    border-color: var(--danger-color);
}
.btn-danger:hover {
    background-color: var(--danger-color);
    color: var(--primary-bg);
}

.btn-success {
    background-color: transparent;
    color: var(--success-color);
    border-color: var(--success-color);
}
.btn-success:hover {
    background-color: var(--success-color);
    color: var(--primary-bg);
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
}

.btn:disabled {
    cursor: not-allowed;
    opacity: 0.5;
    transform: none;
    box-shadow: none;
}
.btn-danger:disabled:hover {
    background-color: transparent;
    color: var(--danger-color);
}

.btn-icon {
    background: transparent;
    border: none;
    color: var(--secondary-text-color);
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0 0.5rem;
}
.btn-icon:hover {
    color: var(--danger-color);
}


/* --- Modal --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    padding: 1rem;
}

.modal-overlay.level-2 {
    z-index: 1010;
}

.modal-overlay.level-3 {
    z-index: 1020;
}


.modal {
    background-color: var(--container-bg);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    width: 100%;
    max-width: 500px;
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    max-height: 90vh;
}

.modal-large {
    max-width: 900px;
}
.modal-xlarge {
    max-width: 1100px;
}


.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
    margin-bottom: 1.5rem;
    flex-shrink: 0;
}

.modal-header h3 {
    color: var(--main-brand-color);
    font-size: 1.5rem;
}

.close-btn {
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--secondary-text-color);
    cursor: pointer;
}

.modal-body {
    overflow-y: auto;
    flex-grow: 1;
}

.form-group {
    margin-bottom: 1.5rem;
}

.modal-body label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--secondary-text-color);
    font-size: 0.9rem;
}

.modal-body input {
    width: 100%;
}

.form-group-checkbox {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.form-group-checkbox label {
    margin-bottom: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}
.form-group-checkbox input[type="checkbox"] {
    width: auto;
    height: 18px;
    width: 18px;
}

.form-static-info {
    font-family: 'Roboto', sans-serif;
    background-color: var(--primary-bg);
    color: var(--secondary-text-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.6rem 1rem;
    font-size: 1rem;
    min-height: 48px;
    display: flex;
    align-items: center;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 1.5rem;
    border-top: 1px solid var(--border-color);
    padding-top: 1rem;
    flex-shrink: 0;
}

/* --- Reports Modal Specifics --- */
.report-controls {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: flex-end;
    margin-bottom: 2rem;
    background-color: rgba(0,0,0,0.1);
    padding: 1.5rem;
    border-radius: 8px;
}
.report-controls .form-group {
    margin-bottom: 0;
    flex-grow: 1;
}
.report-controls .btn {
    flex-shrink: 0;
}
.report-controls select, .report-controls input {
  width: 100%;
}

.report-display {
    margin-top: 1rem;
}

.report-placeholder {
    text-align: center;
    color: var(--secondary-text-color);
    padding: 3rem;
    font-style: italic;
}

.report-title {
  text-align: center;
  margin-bottom: 1.5rem;
  font-weight: 400;
  color: var(--primary-text-color);
}
.report-title small {
  font-size: 0.9rem;
  color: var(--secondary-text-color);
}

/* --- Management Modal --- */
.management-tabs {
  display: flex;
  gap: 0.5rem;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 1.5rem;
}

.tab-btn {
  background: none;
  border: none;
  color: var(--secondary-text-color);
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  cursor: pointer;
  border-bottom: 3px solid transparent;
  transition: all 0.2s;
}

.tab-btn.active, .tab-btn:hover {
  color: var(--primary-text-color);
  border-bottom-color: var(--main-brand-color);
}

.management-content > div > .btn {
  margin-bottom: 1.5rem;
}

.management-list {
  list-style: none;
}

.list-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  border-radius: 8px;
  background-color: rgba(0,0,0,0.1);
  margin-bottom: 0.75rem;
}

.list-item:last-child {
  margin-bottom: 0;
}

.list-item > div:first-child {
  display: flex;
  flex-direction: column;
}

.list-item strong {
  font-weight: 500;
  color: var(--primary-text-color);
}

.list-item small {
  font-size: 0.85rem;
  color: var(--secondary-text-color);
  max-width: 600px;
  white-space: normal;
}

.list-item-main-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.25rem;
}
.unit-main-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}


.status-tag,
.deposit-status-tag {
  padding: 0.2rem 0.6rem;
  border-radius: 12px;
  font-weight: 500;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-tag.status-vacant {
  background-color: rgba(134, 163, 126, 0.15);
  color: var(--success-color);
}

.status-tag.status-occupied {
  background-color: rgba(227, 196, 161, 0.15);
  color: var(--warning-color);
}

.status-tag.status-new {
  background-color: rgba(161, 189, 227, 0.15);
  color: var(--info-color);
}

.status-tag.status-in-progress {
  background-color: rgba(227, 196, 161, 0.15);
  color: var(--warning-color);
}

.status-tag.status-completed {
  background-color: rgba(134, 163, 126, 0.15);
  color: var(--success-color);
}

.status-tag.status-cancelled {
  background-color: rgba(232, 156, 167, 0.15);
  color: var(--danger-color);
}

.status-tag.status-paid-out {
  background-color: rgba(134, 163, 126, 0.15);
  color: var(--success-color);
}

.deposit-status-tag.deposit-paid {
  background-color: rgba(134, 163, 126, 0.15);
  color: var(--success-color);
}

.deposit-status-tag.deposit-outstanding {
  background-color: rgba(227, 196, 161, 0.15);
  color: var(--warning-color);
}

.list-item-actions {
  display: flex;
  gap: 0.75rem;
  flex-shrink: 0;
}

.management-form {
  background-color: rgba(0,0,0,0.1);
  padding: 2rem;
  border-radius: 8px;
}
.management-form h4 {
  font-size: 1.2rem;
  color: var(--main-brand-color);
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 0 1.5rem; /* col gap */
}
.form-span-2 {
    grid-column: 1 / -1;
}

fieldset {
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}
legend {
    padding: 0 0.75rem;
    font-weight: 500;
    color: var(--main-brand-color);
}

.management-form .form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  margin-top: 1.5rem;
}

/* --- Payouts Modal --- */
.payout-summary {
    background-color: rgba(0,0,0,0.1);
    border-radius: 8px;
    padding: 1.5rem 2rem;
    margin-bottom: 2rem;
    border: 1px solid var(--border-color);
}
.payout-summary h3 {
    margin-bottom: 1.5rem;
    color: var(--primary-text-color);
    font-weight: 400;
    text-align: center;
}
.summary-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    font-size: 1.1rem;
}
.summary-item + .summary-item {
    border-top: 1px solid var(--border-color);
}
.income-item span:last-child {
    color: var(--success-color);
    font-weight: 500;
}
.deduction-item span:last-child {
    color: var(--warning-color);
    font-weight: 500;
}
.summary-item.total-item {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--main-brand-color);
    border-top: 2px solid var(--main-brand-color);
    margin-top: 0.5rem;
    padding-top: 1rem;
}
.payout-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}
.payout-details-section h4 {
    font-weight: 500;
    color: var(--secondary-text-color);
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.5rem;
}
.payout-details-section ul {
    list-style: none;
    max-height: 200px;
    overflow-y: auto;
    padding-right: 1rem;
}
.payout-details-section li {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}
.payout-details-section li span:last-child {
    font-weight: 500;
}
.payout-details-section p {
    font-style: italic;
    color: var(--secondary-text-color);
}

/* --- Deposit Process Modal --- */
.error-message {
    color: var(--danger-color);
    margin-top: 1rem;
    font-weight: 500;
    background-color: rgba(232, 156, 167, 0.1);
    border: 1px solid var(--danger-color);
    padding: 1rem;
    border-radius: 8px;
    text-align: center;
}
.deductions-section h4 {
    font-weight: 500;
    color: var(--secondary-text-color);
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.5rem;
}
.deductions-list {
    list-style: none;
    margin-bottom: 1rem;
}
.deductions-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    border-radius: 6px;
    background-color: rgba(0,0,0,0.1);
}
.deductions-list li + li {
    margin-top: 0.5rem;
}

.add-deduction-form {
    display: flex;
    gap: 1rem;
    align-items: center;
    background-color: rgba(0,0,0,0.1);
    padding: 1rem;
    border-radius: 8px;
}
.add-deduction-form input[type="text"] {
    flex-grow: 1;
}
.add-deduction-form input[type="number"] {
    width: 120px;
    flex-shrink: 0;
}

/* --- Receipt Modal --- */
.receipt-container {
    border: 1px solid var(--border-color);
    padding: 2.5rem;
    background-color: var(--primary-bg);
}
.receipt-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    border-bottom: 2px solid var(--main-brand-color);
    padding-bottom: 1.5rem;
    margin-bottom: 1.5rem;
}
.receipt-header h1 {
    color: var(--main-brand-color);
    font-size: 1.8rem;
    margin: 0;
}
.receipt-header p {
    margin:0;
    font-size: 0.8rem;
    letter-spacing: 2px;
}
.receipt-title {
    text-align: right;
}
.receipt-title h2 {
    font-size: 1.5rem;
    margin: 0;
    color: var(--primary-text-color);
}
.receipt-title p {
    font-size: 0.9rem;
    color: var(--secondary-text-color);
}
.receipt-body {
    padding: 1rem 0;
    font-size: 1rem;
}
.receipt-body p {
    margin-bottom: 0.75rem;
}
.receipt-body strong {
    color: var(--secondary-text-color);
    margin-right: 0.5rem;
}
.receipt-amount-box {
    border: 2px solid var(--main-brand-color);
    padding: 1.5rem;
    margin: 2rem 0;
    text-align: center;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--main-brand-color);
    background-color: var(--container-bg);
}
.receipt-footer {
    text-align: center;
    font-size: 0.8rem;
    color: var(--secondary-text-color);
    margin-top: 2rem;
    border-top: 1px solid var(--border-color);
    padding-top: 1rem;
}

/* --- Login Screen --- */
.login-screen-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    flex-grow: 1;
    min-height: 100vh;
    padding: 1rem;
    background: var(--primary-bg);
    gap: 3rem;
}

.login-screen-container .app-header {
    border-bottom: none;
    padding: 0;
}


@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

.login-box {
    width: 100%;
    max-width: 480px;
    background-color: var(--container-bg);
    border: 1px solid var(--border-color);
    border-top: 4px solid var(--main-brand-color);
    border-radius: 12px;
    padding: 4rem;
    box-shadow: var(--shadow);
    text-align: center;
    animation: fadeIn 0.5s ease-out;
}

.login-prompt {
    font-weight: 500;
    font-size: 1.2rem;
    color: var(--primary-text-color);
    margin-bottom: 0.5rem;
}

.login-subprompt {
    color: var(--secondary-text-color);
    margin-bottom: 2.5rem;
    font-size: 0.9rem;
}

.login-welcome-prompt {
    font-size: 1.5rem;
    color: var(--primary-text-color);
    margin-bottom: 0.5rem;
}

.login-box .form-group {
    margin-bottom: 2rem;
    text-align: left;
}
.login-box .form-group label {
    text-align: left;
    display: block;
    margin-bottom: 0.5rem;
    color: var(--secondary-text-color);
}
.login-box .form-group select {
    text-transform: capitalize;
}

.input-with-icon {
    position: relative;
}

.input-with-icon .icon {
    position: absolute;
    left: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--secondary-text-color);
    pointer-events: none;
    height: 1.2em;
    width: 1.2em;
}

.login-box .input-with-icon input {
    font-size: 1.1rem;
    padding: 1.2rem 1.5rem 1.2rem 4rem;
    height: 64px;
}

.login-box .error-message {
    margin-top: 0;
    margin-bottom: 2rem;
}

.login-box .btn-large {
    margin-top: 2rem;
    padding: 1.2rem 2rem;
}

.user-info-bar {
    background-color: var(--container-bg);
    padding: 0.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
}
.user-info-bar p {
    color: var(--secondary-text-color);
    font-size: 0.9rem;
}
.user-info-bar strong {
    color: var(--primary-text-color);
}
.user-info-bar .btn {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
}
.impersonation-bar {
    background-color: var(--warning-color);
    color: var(--primary-bg);
    text-align: center;
    padding: 0.5rem;
    font-weight: 700;
}
.impersonation-bar button {
    margin-left: 1rem;
    background: transparent;
    border: 1px solid var(--primary-bg);
    color: var(--primary-bg);
    cursor: pointer;
}

/* --- WEBSITE STYLES --- */
.website-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.website-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 3rem;
    background-color: var(--primary-bg);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
}
.website-logo h1 {
    font-size: 1.5rem;
    color: var(--main-brand-color);
    letter-spacing: 1px;
}
a.website-logo {
    text-decoration: none;
}
.website-nav {
    display: flex;
    gap: 2.5rem;
}
.website-nav a {
    color: var(--secondary-text-color);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid transparent;
}
.website-nav a:hover {
    color: var(--primary-text-color);
}
.website-nav a.active {
    color: var(--primary-text-color);
    border-bottom-color: var(--main-brand-color);
}
.website-header-actions {
    display: block;
}
.website-header-actions-mobile {
    display: none;
}
.website-header-actions .btn {
    font-size: 0.9rem;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--primary-text-color);
    cursor: pointer;
}
.mobile-menu-toggle svg {
    width: 32px;
    height: 32px;
}

.website-content {
    flex-grow: 1;
}

.website-section {
    padding: 6rem 3rem;
    max-width: 1200px;
    margin: 0 auto;
}
.website-section h2 {
    font-size: 2.5rem;
    color: var(--primary-text-color);
    margin-bottom: 2rem;
    text-align: center;
}
.website-section.alt-bg {
    background-color: var(--container-bg);
}

.hero-section {
    min-height: 80vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 4rem 2rem;
    background: linear-gradient(rgba(30, 30, 30, 0.85), rgba(30, 30, 30, 0.85)), url(https://images.unsplash.com/photo-1600585154340-be6161a56a0c?auto=format&fit=crop&w=1296&q=80) no-repeat center center/cover;
}

.hero-branding {
    margin-bottom: 2rem;
}
.hero-branding h1 {
    font-size: 3.5rem;
    letter-spacing: 2px;
    color: var(--main-brand-color);
}
.hero-branding p {
    font-size: 1.1rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: var(--secondary-text-color);
}

.hero-content h2 {
    font-size: 2.2rem;
    color: #fff;
    margin-bottom: 1rem;
    max-width: 800px;
}
.hero-content p {
    font-size: 1.2rem;
    color: var(--primary-text-color);
    margin-bottom: 2.5rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}
.hero-actions {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}
.hero-actions .btn-large {
    width: auto;
}

.cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}
.service-card {
    background-color: var(--primary-bg);
    padding: 2.5rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}
.service-card h3 {
    color: var(--main-brand-color);
    margin-bottom: 1rem;
}
.service-card p {
    color: var(--secondary-text-color);
}

.testimonial-card {
    background-color: var(--container-bg);
    padding: 2.5rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    position: relative;
    padding-top: 4rem;
}
.testimonial-card::before {
    content: '“';
    position: absolute;
    top: -0.5rem;
    left: 1.5rem;
    font-size: 8rem;
    color: var(--main-brand-color);
    opacity: 0.1;
    line-height: 1;
}
.testimonial-card blockquote {
    font-style: italic;
    color: var(--secondary-text-color);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    border: none;
    padding: 0;
}
.testimonial-card cite {
    font-weight: 700;
    font-style: normal;
    color: var(--primary-text-color);
}


.text-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}
.text-content p {
    margin-bottom: 1.5rem;
    color: var(--secondary-text-color);
    font-size: 1.1rem;
}
.text-content p:last-child {
    margin-bottom: 0;
}

.contact-intro {
    max-width: 600px;
    margin: 0 auto 3rem auto;
    color: var(--secondary-text-color);
    font-size: 1.1rem;
}

.contact-info-container {
    display: flex;
    justify-content: center;
    gap: 4rem;
    margin-top: 3rem;
    flex-wrap: wrap;
}

.contact-info-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-align: center;
}

.contact-info-item span {
    font-size: 1rem;
    color: var(--secondary-text-color);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.contact-info-item a {
    font-size: 1.5rem;
    color: var(--primary-text-color);
    text-decoration: none;
    font-weight: 500;
}
.contact-info-item a:hover {
    color: var(--main-brand-color);
}

.website-footer {
    padding: 2rem 3rem;
    text-align: center;
    color: var(--secondary-text-color);
    border-top: 1px solid var(--border-color);
    background-color: var(--primary-bg);
}


/* --- RESPONSIVE STYLES --- */
@media (max-width: 1024px) {
    .website-header {
        padding: 1rem 1.5rem;
    }
    .website-nav {
        gap: 1.5rem;
    }
    .website-section {
        padding: 4rem 1.5rem;
    }
}

@media (max-width: 768px) {
  main {
    padding: 1rem;
  }

  .app-header {
    padding: 1.5rem 1rem;
    gap: 0.5rem;
  }

  .app-header h1 {
    font-size: 1.75rem;
  }

  .app-header p {
    font-size: 0.8rem;
  }
  
  .login-box {
      padding: 2rem;
  }

  th, td {
    padding: 1rem;
  }
  
  .controls-main-bar {
      flex-direction: column;
      align-items: stretch;
  }
  
  .controls-main-bar .controls {
      width: 100%;
      flex-direction: column;
      align-items: stretch;
  }

  .controls-main-bar .controls .btn,
  .controls-main-bar .controls .date-navigator {
      width: 100%;
  }
  
  .date-navigator {
      justify-content: space-between;
  }

  .rent-roll-header {
      flex-direction: column;
      align-items: stretch;
      margin-top: 1rem;
  }

  .modal {
      width: 95%;
      max-height: 85vh;
      padding: 1.5rem;
  }

  .report-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .payout-details {
      grid-template-columns: 1fr;
  }
  
  .form-grid {
      grid-template-columns: 1fr;
  }
  
  .website-header .website-nav {
      display: none;
      position: absolute;
      top: 100%;
      left: 0;
      right: 0;
      background-color: var(--container-bg);
      flex-direction: column;
      padding: 1rem;
      border-bottom: 1px solid var(--border-color);
      gap: 0;
  }
  .website-header .website-nav.mobile-open {
      display: flex;
  }
  
  .website-nav a {
      padding: 1rem;
      border-bottom: 1px solid var(--border-color);
  }
  .website-nav a:last-child {
      border-bottom: none;
  }
  
  .website-header .mobile-menu-toggle {
      display: block;
  }
  .website-header .website-header-actions {
      display: none;
  }
  
  .website-header-actions-mobile {
      display: block;
      padding: 1rem;
      margin-top: 1rem;
      border-top: 1px solid var(--border-color);
  }
  
  .hero-branding h1 {
      font-size: 2.5rem;
  }
  .hero-content h2 {
      font-size: 1.8rem;
  }
  .hero-actions {
      flex-direction: column;
  }
  .hero-actions .btn-large {
      width: 100%;
  }

}
