/* ========================================
   CSS VARIABLES & GLOBAL SETUP
======================================== */
:root{
    --brown:#6d553c;
    --accent:#d9a24a;
    --muted:#8a8f8f;
    --card-bg: #ffffff;
    --panel-shadow: 0 6px 18px rgba(12,12,12,0.06);
}

html,body{ height:100%; }
body{
    font-family: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
    background:#f5f6f7;
    margin:0;
    color:#222;
}

/* Dashboard wrapper */
.app-wrap{
    padding: 0 16px;
}
.dashboard { margin-top: 18px; }

/* ========================================
   METRIC CARDS (TOP BOXES)
======================================== */
.metric-card{
    border-radius: 10px;
    color: #fff;
    padding: 16px;
    box-shadow: var(--panel-shadow);
    height:100%;
    display:flex;
    flex-direction:column;
    justify-content:space-between;
}

.metric-card .value{
    font-size: clamp(20px,3.6vw,34px);
    font-weight:700;
    margin-top:8px;
}
.metric-card .label{
    opacity:.95;
    font-weight:700;
    font-size:0.95rem;
}
.metric-card .small-muted {
    color: #000;          /* Black for visibility */
    opacity: 0.7;         /* Keeps it subtle, not harsh */
}

/* Gradient backgrounds */
.metric-blue{ background: linear-gradient(90deg,#5da6df,#4aa0d3); }
.metric-copper{ background: linear-gradient(90deg,#c88659,#bd7d4d); }
.metric-green{ background: linear-gradient(90deg,#64c18a,#56b872); }
.metric-red{ background: linear-gradient(90deg,#e06666,#d65353); }

/* ========================================
   PANELS (SIDE CARDS)
======================================== */
.panel{
    background: var(--card-bg);
    border-radius: 8px;
    padding: 12px;
    box-shadow: var(--panel-shadow);
    height:auto;
    min-height: 72px;
    display:flex;
    flex-direction:column;
}
.panel .panel-title{
    font-weight:700;
    color:#333;
    display:flex;
    align-items:center;
    justify-content:space-between;
    padding-bottom:8px;
    border-bottom:1px solid #eee;
}

.quick-btn{
    border-radius:6px;
    padding:10px 16px;
    box-shadow: 0 6px 14px rgba(16,16,16,0.05);
    font-weight:600;
    border:none;
}
.quick-btn.reserve{ background: #5da6df; color:#fff; }
.quick-btn.checkin{ background: #c88659; color:#fff; }

.stat-row{
    display:flex;
    align-items:center;
    justify-content:space-between;
    padding:10px 0;
    border-bottom:1px dashed #eee;
}
.stat-row:last-child{ border-bottom:none; }

/* ========================================
   CHART CARD + CANVAS
======================================== */
.chart-card{
    background: var(--card-bg);
    border-radius: 8px;
    padding: 14px;
    box-shadow: var(--panel-shadow);
    display:flex;
    flex-direction:column;
    gap:8px;
    min-height: 260px;
}

.chart-canvas-wrap{
    flex: 1 1 auto;
    min-height: 180px;
    max-height: 420px;
    position: relative;
}

#roomChart {
    width:100% !important;
    height:100% !important;
    display:block;
}

.chart-legend{
    font-weight:600;
    color:#666;
    margin-bottom:4px;
}

/* Badges */
.badge-green{ background: #28a745; color:#fff; padding:8px 12px; border-radius:6px; font-weight:700; }
.badge-red{ background: #e05656; color:#fff; padding:8px 12px; border-radius:6px; font-weight:700; }

/* Muted text */
.small-muted{ color:var(--muted); font-size:0.92rem; }

/* ========================================
   NAVBAR
======================================== */
.navbar-admin{
    display:flex;
    align-items:center;
    justify-content:space-between;
    background-color:#655233;
    color:white;
    padding:10px 20px;
    position:relative;
    flex-wrap:wrap;
}

.navbar-left{ display:flex; align-items:center; gap:10px; }
.navbar-logo{
    height:45px;
    width:120px;
    object-fit:contain;
    cursor:pointer;
}

.navbar-center{
    display:flex;
    align-items:center;
    justify-content:end;
    flex:1;
    gap:7px;
    flex-wrap:wrap;
}

.navbar-center a{
    display:flex;
    align-items:center;
    color:#d4d7dc;
    text-decoration:none;
    font-size:0.95rem;
    padding:10px 12px;
    border-radius:6px;
    transition:background .3s ease, color .3s ease;
}
.navbar-center a.active{ background-color:#6e5835; color:white; }
.navbar-center a:hover{ background-color:#655233; color:white; }

/* Dropdown */
.dropdown{ position:relative; }
.dropdown-menu{
    display:none;
    flex-direction:column;
    position:absolute;
    top:100%;
    left:0;
    background-color:#6e5835;
    border-radius:8px;
    min-width:240px;
    z-index:100;
}
.dropdown:hover > .dropdown-menu{ display:flex; }

.dropdown-submenu{ position:relative; }
.dropdown-submenu .submenu{
    display:none;
    position:absolute;
    top:0;
    left:100%;
    flex-direction:column;
    background-color:#6e5835;
    border-radius:8px;
    min-width:220px;
}
.dropdown-submenu:hover > .submenu{ display:flex; }

/* Profile */
.profile-dropdown{ position:relative; margin-left:15px; }
.profile-icon{
    width:38px;
    height:38px;
    border-radius:50%;
    overflow:hidden;
    background-color:#d4d7dc1a;
    cursor:pointer;
    border:2px solid #444;
    transition:border-color .3s ease, transform .2s ease;
}
.profile-icon img{ width:100%; height:100%; object-fit:cover; }
.profile-icon:hover{
    border-color:#00b4d8;
    transform:scale(1.05);
}
.profile-card{
    display:none;
    flex-direction:column;
    position:absolute;
    top:110%;
    right:0;
    background-color:#F0F0F0;
    border-radius:10px;
    box-shadow:0 4px 10px rgba(0,0,0,0.4);
    padding:15px;
    min-width:180px;
    z-index:200;
}
.profile-dropdown.active .profile-card{ display:flex; }

/* ========================================
   RESPONSIVE
======================================== */
@media screen and (max-width:1024px){
    .navbar-admin{
        position:fixed;
        top:0; left:0;
        width:100%;
        z-index:9999;
        padding:27px 15px;
    }
    body.admin-page{ padding-top:70px; }
    .navbar-logo{ display:none; }
    .hamburger{
        position:absolute;
        top:18px;
        left:20px;
        display:flex;
        flex-direction:column;
        justify-content:space-around;
        width:28px;
        height:22px;
        cursor:pointer;
    }
    .hamburger span{
        display:block;
        height:3px;
        background:#d4d7dc;
        border-radius:2px;
        transition:.3s;
    }
    .navbar-center{
        display:none;
        flex-direction:column;
        width:50%;
        background-color:#655233;
        padding:3px 0;
        position:absolute;
        top:52px;
        left:0;
        z-index:9999;
        align-items:flex-start;
    }
    .navbar-admin.expanded .navbar-center{ display:flex; }
}

@media (max-width:991px){
    .metric-card .value{ font-size:20px; }
}

@media (max-width:575px){
    .app-wrap{ margin:10px; }
    .chart-card{ min-height:200px; }
}

.profile-card p {
    color: #333 !important;
    font-weight: 600;
}

.dashboard-link,
.dashboard-link:visited,
.dashboard-link:hover,
.dashboard-link:active {
    color: #fff !important;              /* keep badge/button text color */
    text-decoration: none;       /* remove underline */
}

/* Optional: pointer & smooth hover */
.dashboard-link {
    cursor: pointer;
}