/* ============================================================
   ICONEVILLE USER PAGES - ENHANCED DESIGN SYSTEM
   A modern, clean, and professional design for all user pages
   ============================================================ */

:root {
    /* Color Palette */
    --primary-dark: #0A5E2A;
    --primary-light: #1a7a3c;
    --accent-red: #FE0000;
    --accent-red-dark: #d90000;
    --neutral-bg: #EFEFE8;
    --neutral-light: #f5f4f0;
    --neutral-white: #ffffff;
    --text-dark: #0f0f0f;
    --text-secondary: #5b5b5b;
    --text-tertiary: #8b8b8b;
    --border-light: #e8e8e8;
    --border-medium: #d8d8d8;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 8px 16px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 16px 32px rgba(0, 0, 0, 0.15);
    --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.2);
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.6s ease;
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
}

/* ============================================================
   BASE STYLES
   ============================================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
}

body {
    background-color: var(--neutral-bg);
    color: var(--text-dark);
    font-size: 15px;
    line-height: 1.6;
}

.user-wrapper {
    min-height: calc(100vh - 70px);
    background-color: var(--neutral-bg);
    padding: 0;
}

.user-content {
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
    width: 100%;
}

.section-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 16px;
    width: 100%;
}

/* ============================================================
   TYPOGRAPHY
   ============================================================ */

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-dark);
}

h1 {
    font-size: 48px;
}

h2 {
    font-size: 40px;
}

h3 {
    font-size: 28px;
}

h4 {
    font-size: 20px;
}

h5 {
    font-size: 16px;
}

h6 {
    font-size: 14px;
}

p {
    color: var(--text-secondary);
}

a {
    color: var(--primary-dark);
    text-decoration: none;
    transition: var(--transition-fast);
}

a:hover {
    color: var(--primary-light);
}

/* ============================================================
   BUTTONS & LINKS
   ============================================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 20px;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 13px;
    border: none;
    cursor: pointer;
    transition: all var(--transition-normal);
    text-decoration: none;
}

.btn-primary {
    background-color: var(--primary-dark);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-secondary {
    background-color: var(--neutral-light);
    color: var(--primary-dark);
    border: 1px solid var(--border-light);
}

.btn-secondary:hover {
    background-color: var(--border-light);
    transform: translateY(-2px);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary-dark);
    border: 2px solid var(--primary-dark);
}

.btn-outline:hover {
    background-color: rgba(10, 94, 42, 0.08);
    transform: translateY(-2px);
}

.btn-danger {
    background-color: var(--accent-red);
    color: white;
}

.btn-danger:hover {
    background-color: var(--accent-red-dark);
    transform: translateY(-2px);
}

.btn-sm {
    padding: 6px 14px;
    font-size: 12px;
}

.btn-lg {
    padding: 12px 28px;
    font-size: 14px;
}

.btn-icon {
    padding: 8px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

/* ============================================================
   BADGES & LABELS
   ============================================================ */

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.badge-primary {
    background: rgba(10, 94, 42, 0.1);
    color: var(--primary-dark);
}

.badge-secondary {
    background: rgba(254, 0, 0, 0.1);
    color: #c41c1c;
}

.badge-success {
    background: rgba(76, 175, 80, 0.1);
    color: #2d7a2d;
}

.badge-warning {
    background: rgba(255, 152, 0, 0.1);
    color: #cc7a00;
}

.badge-danger {
    background: rgba(244, 67, 54, 0.1);
    color: #c41c1c;
}

.label {
    display: block;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 6px;
    color: var(--text-dark);
}

.label-required::after {
    content: ' *';
    color: var(--accent-red);
}

/* ============================================================
   FORMS
   ============================================================ */

.form-group {
    margin-bottom: 14px;
}

.form-group label {
    display: block;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 6px;
    color: var(--text-dark);
}

.required {
    color: var(--accent-red);
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="phone"],
input[type="date"],
input[type="number"],
select,
textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    font-family: inherit;
    font-size: 14px;
    transition: all var(--transition-fast);
    background: var(--neutral-white);
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="phone"]:focus,
input[type="date"]:focus,
input[type="number"]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary-dark);
    box-shadow: 0 0 0 3px rgba(10, 94, 42, 0.1);
}

textarea {
    resize: vertical;
    min-height: 120px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-row-3 {
    grid-template-columns: repeat(3, 1fr);
}

.input-group {
    display: flex;
    gap: 8px;
}

.input-group input,
.input-group select {
    flex: 1;
}

/* ============================================================
   CARDS
   ============================================================ */

.card {
    background: var(--neutral-white);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    padding: 16px;
    transition: all var(--transition-normal);
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-dark);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-light);
}

.card-header h3 {
    font-size: 18px;
    margin: 0;
}

.card-body {
    flex: 1;
}

.card-footer {
    display: flex;
    gap: 12px;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border-light);
}

.card-horizontal {
    display: flex;
    gap: 20px;
    align-items: center;
}

.card-horizontal .card-image {
    flex-shrink: 0;
    width: 120px;
    height: 120px;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.card-horizontal .card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ============================================================
   GRID LAYOUTS
   ============================================================ */

.grid {
    display: grid;
    gap: 16px;
}

.grid-cols-2 {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid-cols-3 {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.grid-cols-4 {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

/* ============================================================
   PROPERTY/LOT CARDS
   ============================================================ */

.property-card {
    background: var(--neutral-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border-light);
    transition: all var(--transition-normal);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.property-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-dark);
}

.property-image {
    position: relative;
    overflow: hidden;
    height: 180px;
    background: var(--neutral-light);
}

.property-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-normal);
}

.property-card:hover .property-image img {
    transform: scale(1.08);
}

.property-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--accent-red);
    color: white;
    padding: 6px 14px;
    border-radius: var(--radius-sm);
    font-size: 11px;
    font-weight: 700;
    z-index: 1;
}

.property-content {
    padding: 14px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.property-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 2px;
}

.property-project {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.property-location {
    font-size: 13px;
    color: var(--text-tertiary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.property-specs {
    display: flex;
    gap: 12px;
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-light);
    flex-wrap: wrap;
}

.property-spec {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.property-spec-value {
    font-size: 14px;
    font-weight: 700;
    color: var(--primary-dark);
}

.property-spec-label {
    font-size: 11px;
    color: var(--text-tertiary);
}

.property-price {
    font-size: 20px;
    font-weight: 700;
    color: var(--accent-red);
    margin-bottom: 12px;
}

.property-actions {
    display: flex;
    gap: 8px;
    margin-top: auto;
}

.property-actions .btn {
    flex: 1;
}

/* ============================================================
   ALERTS & NOTIFICATIONS
   ============================================================ */

.alert {
    padding: 12px 14px;
    border-radius: var(--radius-md);
    margin-bottom: 14px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 13px;
    border-left: 4px solid;
}

.alert i {
    font-size: 18px;
    flex-shrink: 0;
    margin-top: 2px;
}

.alert-success {
    background: rgba(76, 175, 80, 0.1);
    color: #2d7a2d;
    border-left-color: #2d7a2d;
}

.alert-error {
    background: rgba(244, 67, 54, 0.1);
    color: #c41c1c;
    border-left-color: #c41c1c;
}

.alert-warning {
    background: rgba(255, 152, 0, 0.1);
    color: #cc7a00;
    border-left-color: #cc7a00;
}

.alert-info {
    background: rgba(33, 150, 243, 0.1);
    color: #1565c0;
    border-left-color: #1565c0;
}

/* ============================================================
   TABLES
   ============================================================ */

.table-responsive {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: var(--neutral-white);
}

table thead {
    background: var(--neutral-light);
    border-bottom: 2px solid var(--border-light);
}

table th {
    padding: 14px 16px;
    text-align: left;
    font-weight: 600;
    font-size: 13px;
    color: var(--text-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-light);
}

table tbody tr:hover {
    background: var(--neutral-light);
}

table tbody tr:last-child td {
    border-bottom: none;
}

/* ============================================================
   MODALS
   ============================================================ */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn var(--transition-normal);
}

.modal {
    background: var(--neutral-white);
    border-radius: var(--radius-lg);
    max-width: 500px;
    width: 90%;
    box-shadow: var(--shadow-xl);
    animation: slideUp var(--transition-normal);
}

.modal-header {
    padding: 16px;
    border-bottom: 1px solid var(--border-light);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    font-size: 20px;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-tertiary);
    transition: var(--transition-fast);
}

.modal-close:hover {
    color: var(--text-dark);
}

.modal-body {
    padding: 16px;
}

.modal-footer {
    padding: 12px 16px;
    border-top: 1px solid var(--border-light);
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

/* ============================================================
   TABS
   ============================================================ */

.tabs {
    display: flex;
    gap: 0;
    border-bottom: 2px solid var(--border-light);
    margin-bottom: 24px;
}

.tab-button {
    background: none;
    border: none;
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all var(--transition-fast);
}

.tab-button:hover {
    color: var(--primary-dark);
}

.tab-button.active {
    color: var(--primary-dark);
    border-bottom-color: var(--primary-dark);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn var(--transition-fast);
}

/* ============================================================
   BREADCRUMBS
   ============================================================ */

.breadcrumb {
    display: flex;
    gap: 8px;
    align-items: center;
    font-size: 13px;
    margin-bottom: 24px;
}

.breadcrumb a {
    color: var(--primary-dark);
    transition: var(--transition-fast);
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb .separator {
    color: var(--text-tertiary);
}

.breadcrumb .current {
    color: var(--text-secondary);
}

/* ============================================================
   STATUS INDICATORS
   ============================================================ */

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.status-available {
    background: rgba(76, 175, 80, 0.1);
    color: #4caf50;
}

.status-sold {
    background: rgba(244, 67, 54, 0.1);
    color: #f44336;
}

.status-reserved {
    background: rgba(255, 152, 0, 0.1);
    color: #ff9800;
}

.status-active {
    background: rgba(76, 175, 80, 0.1);
    color: #4caf50;
}

.status-inactive {
    background: rgba(158, 158, 158, 0.1);
    color: #666666;
}

/* ============================================================
   PAGINATION
   ============================================================ */

.pagination {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin: 32px 0;
}

.pagination a,
.pagination button {
    padding: 8px 12px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    background: var(--neutral-white);
    color: var(--primary-dark);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-weight: 600;
}

.pagination a:hover,
.pagination button:hover {
    background: var(--primary-dark);
    color: white;
}

.pagination .active {
    background: var(--primary-dark);
    color: white;
    border-color: var(--primary-dark);
}

.pagination .disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ============================================================
   ANIMATIONS
   ============================================================ */

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideRight {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

/* ============================================================
   SIDEBAR NAVIGATION
   ============================================================ */

.user-sidebar {
    background: var(--neutral-white);
    border-right: 1px solid var(--border-light);
    width: 280px;
    min-height: calc(100vh - 70px);
    padding: 24px 0;
    position: sticky;
    top: 70px;
}

.sidebar-section {
    margin-bottom: 24px;
}

.sidebar-title {
    font-size: 12px;
    font-weight: 700;
    color: var(--text-tertiary);
    text-transform: uppercase;
    padding: 0 20px;
    margin-bottom: 12px;
    letter-spacing: 0.5px;
}

.sidebar-menu {
    list-style: none;
}

.sidebar-item {
    margin: 0;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 20px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    transition: all var(--transition-fast);
    border-left: 3px solid transparent;
}

.sidebar-link:hover {
    background: var(--neutral-light);
    color: var(--primary-dark);
    border-left-color: var(--primary-dark);
}

.sidebar-link.active {
    background: rgba(10, 94, 42, 0.08);
    color: var(--primary-dark);
    font-weight: 600;
    border-left-color: var(--primary-dark);
}

.sidebar-icon {
    width: 20px;
    font-size: 16px;
}

/* ============================================================
   PAGE SECTIONS
   ============================================================ */

.page-header {
    background: var(--neutral-white);
    padding: 20px 16px;
    border-bottom: 1px solid var(--border-light);
    margin-bottom: 16px;
}

.page-header h1 {
    margin: 0 0 4px 0;
    font-size: 28px;
}

.page-header p {
    margin: 0;
    color: var(--text-secondary);
}

.page-section {
    margin-bottom: 20px;
}

.section-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--primary-dark);
}

/* ============================================================
   EMPTY STATE
   ============================================================ */

.empty-state {
    text-align: center;
    padding: 80px 24px;
    background: var(--neutral-white);
    border-radius: var(--radius-lg);
    border: 2px dashed var(--border-light);
}

.empty-state-icon {
    font-size: 64px;
    color: var(--text-tertiary);
    margin-bottom: 16px;
}

.empty-state h3 {
    font-size: 20px;
    margin-bottom: 8px;
    color: var(--text-dark);
}

.empty-state p {
    margin-bottom: 24px;
    color: var(--text-secondary);
}

/* ============================================================
   LOADING STATES
   ============================================================ */

.skeleton {
    background: linear-gradient(90deg, var(--border-light) 25%, var(--neutral-light) 50%, var(--border-light) 75%);
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

.skeleton-text {
    height: 16px;
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
}

.skeleton-image {
    width: 100%;
    padding-bottom: 100%;
    border-radius: var(--radius-lg);
}

/* ============================================================
   RESPONSIVE DESIGN
   ============================================================ */

@media (max-width: 1024px) {
    .grid-cols-4 {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .form-row-3 {
        grid-template-columns: repeat(2, 1fr);
    }

    .user-sidebar {
        width: 240px;
    }
}

@media (max-width: 768px) {
    h1 {
        font-size: 24px;
    }

    h2 {
        font-size: 20px;
    }

    h3 {
        font-size: 16px;
    }

    .section-container {
        padding: 12px;
    }

    .grid-cols-2,
    .grid-cols-3,
    .grid-cols-4 {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .form-row,
    .form-row-3 {
        grid-template-columns: 1fr;
    }

    .page-header {
        padding: 16px 12px;
        margin-bottom: 12px;
    }

    .page-header h1 {
        font-size: 20px;
        margin-bottom: 2px;
    }

    .card-horizontal {
        flex-direction: column;
        align-items: flex-start;
    }

    .card-horizontal .card-image {
        width: 100%;
        height: 150px;
    }

    .modal {
        width: 95%;
    }

    .tabs {
        overflow-x: auto;
    }

    .tab-button {
        white-space: nowrap;
        padding: 8px 14px;
        font-size: 12px;
    }

    table {
        font-size: 11px;
    }

    table th,
    table td {
        padding: 8px 6px;
    }

    .btn {
        width: 100%;
    }
}

@media (max-width: 640px) {
    body {
        font-size: 13px;
    }

    h1 {
        font-size: 20px;
    }

    h2 {
        font-size: 18px;
    }

    .section-container {
        padding: 8px;
    }

    .input-group {
        flex-direction: column;
        gap: 6px;
    }

    .property-specs {
        flex-direction: column;
        gap: 6px;
    }

    .alert {
        flex-direction: column;
        padding: 10px 12px;
    }

    .modal-footer {
        flex-direction: column-reverse;
        gap: 8px;
    }

    .modal-footer .btn {
        width: 100%;
        padding: 10px 16px;
    }

    .user-sidebar {
        display: none;
    }
}
