/* LNE Sweet Home — Admin Panel Styles
   Colors match the public site:
   Primary red:   #f7395a
   Navy:          #24355a
   Orange CTA:    #f39c12
   Body text:     #767676
   Fonts: Nunito (headings), Open Sans (body)
*/

:root {
    --lne-red:    #f7395a;
    --lne-navy:   #24355a;
    --lne-orange: #f39c12;
    --lne-orange-dark: #e67e22;
    --lne-light:  #f8f9fa;
    --lne-shadow: rgba(247, 57, 90, 0.15);
}

* { box-sizing: border-box; }

body {
    font-family: 'Open Sans', sans-serif;
    font-size: 14px;
    color: #767676;
    background-color: #f4f6f9;
    margin: 0;
}

h1, h2, h3, h4, h5, h6, .navbar-brand {
    font-family: 'Nunito', sans-serif;
    color: var(--lne-navy);
    font-weight: 700;
}

/* ── Navbar ───────────────────────────────────────────── */
.lne-navbar {
    background: var(--lne-navy);
    padding: 0.6rem 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    position: sticky;
    top: 0;
    z-index: 1030;
}

.lne-navbar .nav-link,
.lne-navbar .navbar-brand {
    color: rgba(255,255,255,0.9) !important;
    transition: color 0.2s;
}

.lne-navbar .nav-link:hover,
.lne-navbar .nav-item.active .nav-link {
    color: var(--lne-orange) !important;
}

.lne-navbar .nav-item.active .nav-link {
    border-bottom: 2px solid var(--lne-orange);
}

.brand-lne    { color: var(--lne-red) !important; font-size: 1.3rem; }
.brand-sweet  { color: #fff !important; font-size: 1.3rem; }
.brand-admin  {
    display: inline-block;
    background: var(--lne-orange);
    color: #fff !important;
    font-size: 0.65rem;
    padding: 1px 6px;
    border-radius: 3px;
    vertical-align: middle;
    margin-left: 6px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.lne-navbar .dropdown-menu {
    border: none;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    border-radius: 8px;
}

/* ── Content area ─────────────────────────────────────── */
.lne-content {
    padding: 1.5rem 0.5rem;
    min-height: calc(100vh - 120px);
}

/* ── Page header ──────────────────────────────────────── */
.page-header-lne {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #e9ecef;
}

.page-header-lne h1 {
    font-size: 1.6rem;
    margin: 0;
}

/* ── Buttons ──────────────────────────────────────────── */
.btn-lne-primary {
    background: var(--lne-red);
    border-color: var(--lne-red);
    color: #fff;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    border-radius: 20px;
    padding: 0.4rem 1.2rem;
    transition: background 0.2s, box-shadow 0.2s;
}
.btn-lne-primary:hover {
    background: #d42e4a;
    border-color: #d42e4a;
    color: #fff;
    box-shadow: 0 4px 12px var(--lne-shadow);
}

.btn-lne-orange {
    background: var(--lne-orange);
    border-color: var(--lne-orange);
    color: #fff;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    border-radius: 20px;
    padding: 0.4rem 1.2rem;
    transition: background 0.2s;
}
.btn-lne-orange:hover {
    background: var(--lne-orange-dark);
    border-color: var(--lne-orange-dark);
    color: #fff;
}

/* ── Cards / panels ───────────────────────────────────── */
.lne-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.07);
    border: none;
    overflow: hidden;
}

.lne-card .card-header {
    background: var(--lne-navy);
    color: #fff;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    border-radius: 12px 12px 0 0 !important;
    padding: 0.75rem 1.25rem;
}

/* ── Property table ───────────────────────────────────── */
.prop-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.prop-table th {
    background: var(--lne-navy);
    color: #fff;
    font-family: 'Nunito', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0.75rem 1rem;
    border: none;
    white-space: nowrap;
}
.prop-table th:first-child { border-radius: 8px 0 0 0; }
.prop-table th:last-child  { border-radius: 0 8px 0 0; }

.prop-table td {
    padding: 0.7rem 1rem;
    vertical-align: middle;
    border-bottom: 1px solid #f0f0f0;
    font-size: 0.9rem;
}

.prop-table tbody tr:hover td {
    background: #fffbf0;
}

.prop-thumb {
    width: 64px;
    height: 48px;
    object-fit: cover;
    border-radius: 6px;
    border: 2px solid var(--lne-orange);
}

.prop-thumb-placeholder {
    width: 64px;
    height: 48px;
    background: #e9ecef;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #aaa;
    font-size: 1.2rem;
}

/* ── Badges ───────────────────────────────────────────── */
.badge-active {
    background: #d4edda;
    color: #155724;
    font-size: 0.75rem;
    padding: 3px 8px;
    border-radius: 20px;
    font-weight: 600;
}
.badge-inactive {
    background: #f8d7da;
    color: #721c24;
    font-size: 0.75rem;
    padding: 3px 8px;
    border-radius: 20px;
    font-weight: 600;
}

/* ── Action buttons in table ──────────────────────────── */
.btn-action {
    padding: 4px 10px;
    font-size: 0.8rem;
    border-radius: 15px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: opacity 0.2s;
}
.btn-action:hover { opacity: 0.85; }
.btn-edit   { background: var(--lne-navy);   color: #fff; }
.btn-delete { background: var(--lne-red);    color: #fff; }

/* ── Forms ────────────────────────────────────────────── */
.lne-form-section {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.07);
    padding: 1.5rem 2rem;
    margin-bottom: 1.5rem;
}

.lne-form-section h5 {
    color: var(--lne-navy);
    font-size: 1rem;
    font-weight: 700;
    border-left: 3px solid var(--lne-orange);
    padding-left: 0.6rem;
    margin-bottom: 1rem;
}

.form-control:focus {
    border-color: var(--lne-red);
    box-shadow: 0 0 0 0.15rem var(--lne-shadow);
}

label {
    font-weight: 600;
    color: var(--lne-navy);
    font-size: 0.85rem;
    margin-bottom: 0.25rem;
}

/* ── Image preview grid ───────────────────────────────── */
.img-preview-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.img-preview-item {
    position: relative;
    width: 110px;
}

.img-preview-item img {
    width: 110px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    border: 2px solid #e9ecef;
    transition: border-color 0.2s;
}

.img-preview-item img:hover {
    border-color: var(--lne-orange);
}

.img-preview-item .btn-remove-img {
    position: absolute;
    top: -6px;
    right: -6px;
    width: 20px;
    height: 20px;
    background: var(--lne-red);
    color: #fff;
    border: none;
    border-radius: 50%;
    font-size: 11px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.img-preview-item .badge-primary-img {
    position: absolute;
    bottom: 4px;
    left: 4px;
    background: var(--lne-orange);
    color: #fff;
    font-size: 0.6rem;
    padding: 1px 5px;
    border-radius: 3px;
    font-weight: 700;
}

/* ── Login page ───────────────────────────────────────── */
.login-wrapper {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--lne-navy) 0%, #1a2742 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    padding: 2.5rem 2rem;
    width: 100%;
    max-width: 380px;
}

.login-logo {
    text-align: center;
    margin-bottom: 1.5rem;
}

.login-logo .brand-lne   { font-size: 2rem; }
.login-logo .brand-sweet { font-size: 2rem; color: var(--lne-navy); }
.login-logo .brand-admin {
    display: block;
    margin: 0.25rem auto 0;
    width: fit-content;
    font-size: 0.7rem;
}

.login-card .form-control {
    border-radius: 8px;
    padding: 0.55rem 0.9rem;
}

.btn-login {
    background: linear-gradient(135deg, var(--lne-red), #d42e4a);
    border: none;
    border-radius: 25px;
    color: #fff;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 1rem;
    width: 100%;
    padding: 0.6rem;
    margin-top: 0.5rem;
    transition: box-shadow 0.2s;
}
.btn-login:hover {
    box-shadow: 0 6px 20px var(--lne-shadow);
    color: #fff;
}

/* ── Alerts ───────────────────────────────────────────── */
.alert { border-radius: 10px; font-size: 0.9rem; }

/* ── Footer ───────────────────────────────────────────── */
.lne-footer {
    background: var(--lne-navy);
    color: rgba(255,255,255,0.5);
    padding: 0.75rem 0;
    font-size: 0.8rem;
    margin-top: 2rem;
}

/* ── Responsive ───────────────────────────────────────── */
@media (max-width: 768px) {
    .lne-content { padding: 1rem 0.25rem; }
    .lne-form-section { padding: 1rem; }
    .page-header-lne { flex-direction: column; align-items: flex-start; gap: 0.75rem; }
}
