/* =====================================================
   STYLE.CSS - Frontend (User) Catering Kantor
   ===================================================== */

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f5f6fa;
    color: #2c3e50;
    line-height: 1.6;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }

/* ============ NAVBAR ============ */
.navbar {
    background: #2c3e50;
    color: #fff;
    padding: 0 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    position: sticky;
    top: 0;
    z-index: 1000;
    min-height: 60px;
    flex-wrap: wrap;
}

.navbar .logo {
    font-size: 22px;
    font-weight: bold;
    color: #f39c12;
    padding: 15px 0;
    white-space: nowrap;
    flex-shrink: 0;
}

.navbar .logo span { color: #fff; }

/* Desktop menu */
.navbar ul {
    list-style: none;
    display: flex;
    gap: 25px;
    margin: 0;
    padding: 0;
}

.navbar ul li a {
    color: #fff;
    font-weight: 500;
    transition: color .2s;
    white-space: nowrap;
}

.navbar ul li a:hover,
.navbar ul li a.active {
    color: #f39c12;
}

/* ---- Hamburger button (hidden on desktop) ---- */
.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 34px;
    height: 24px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
}

.nav-toggle span {
    display: block;
    width: 100%;
    height: 3px;
    background: #fff;
    border-radius: 3px;
    transition: transform .3s ease, opacity .2s ease;
    transform-origin: center;
}

.nav-toggle.open span:nth-child(1) { transform: translateY(10.5px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-toggle.open span:nth-child(3) { transform: translateY(-10.5px) rotate(-45deg); }

/* ============ MOBILE NAVBAR ============ */
@media (max-width: 768px) {
    .navbar {
        padding: 0 16px;
    }

    .nav-toggle {
        display: flex;
    }

    /* Hide menu by default on mobile */
    .navbar ul {
        display: none !important;
        flex-direction: column;
        width: calc(100% + 32px);
        margin: 0 -16px;
        padding: 6px 0 10px;
        background: #1e2d3d;
        gap: 0;
        order: 3;
    }

    /* Show when toggled */
    .navbar ul.open {
        display: flex !important;
    }

    .navbar ul li a {
        display: block;
        padding: 13px 20px;
        border-bottom: 1px solid rgba(255,255,255,0.07);
        font-size: 15px;
        white-space: normal;
    }

    .navbar ul li:last-child a {
        border-bottom: none;
    }
}

/* ============ HERO ============ */
.hero {
    background: linear-gradient(rgba(44,62,80,0.75), rgba(44,62,80,0.75)),
                url('https://images.unsplash.com/photo-1555244162-803834f70033?auto=format&fit=crop&w=1400');
    background-size: cover;
    background-position: center;
    color: #fff;
    text-align: center;
    padding: 90px 20px;
}

.hero h1 {
    font-size: 42px;
    margin-bottom: 15px;
}

.hero p {
    font-size: 18px;
    margin-bottom: 25px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* ============ BUTTONS ============ */
.btn {
    display: inline-block;
    background: #f39c12;
    color: #fff !important;
    padding: 12px 28px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    transition: all .2s;
}

.btn:hover { background: #e67e22; transform: translateY(-2px); }

.btn-secondary {
    background: #34495e;
}

.btn-secondary:hover { background: #2c3e50; }

.btn-danger {
    background: #e74c3c;
}

.btn-danger:hover { background: #c0392b; }

.btn-sm {
    padding: 6px 12px;
    font-size: 13px;
}

/* ============ SECTION ============ */
.section {
    padding: 60px 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    font-size: 30px;
    margin-bottom: 10px;
    color: #2c3e50;
}

.section-sub {
    text-align: center;
    color: #7f8c8d;
    margin-bottom: 40px;
}

/* ============ FEATURES ============ */
.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 25px;
}

.feature-card {
    background: #fff;
    padding: 25px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: transform .2s;
}

.feature-card:hover { transform: translateY(-5px); }

.feature-card .icon {
    font-size: 40px;
    color: #f39c12;
    margin-bottom: 10px;
}

.feature-card h3 {
    margin-bottom: 8px;
    color: #2c3e50;
}

/* ============ MENU GRID ============ */
.menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 25px;
}

.menu-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: transform .2s, box-shadow .2s;
    display: flex;
    flex-direction: column;
}

.menu-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}

.menu-card .img-wrap {
    height: 180px;
    background: linear-gradient(135deg, #f39c12, #e67e22);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 60px;
}

.menu-card .body {
    padding: 18px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.menu-card .kategori {
    background: #ecf0f1;
    color: #34495e;
    font-size: 12px;
    padding: 3px 10px;
    border-radius: 4px;
    display: inline-block;
    margin-bottom: 8px;
    width: fit-content;
}

.menu-card h3 {
    color: #2c3e50;
    margin-bottom: 8px;
    font-size: 18px;
}

.menu-card .desc {
    color: #7f8c8d;
    font-size: 14px;
    flex: 1;
    margin-bottom: 12px;
}

.menu-card .harga {
    color: #e67e22;
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 10px;
}

.menu-card .min-porsi {
    font-size: 12px;
    color: #95a5a6;
    margin-bottom: 12px;
}

/* ============ FORM ============ */
.form-box {
    background: #fff;
    padding: 35px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    max-width: 700px;
    margin: 0 auto;
}

.form-box h2 {
    color: #2c3e50;
    margin-bottom: 20px;
    text-align: center;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    color: #34495e;
    font-weight: 600;
    font-size: 14px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #bdc3c7;
    border-radius: 5px;
    font-size: 14px;
    font-family: inherit;
    transition: border .2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #f39c12;
}

.form-group textarea { resize: vertical; min-height: 80px; }

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

@media (max-width:600px){
    .form-row { grid-template-columns: 1fr; }
}

/* ============ ALERT ============ */
.alert {
    padding: 12px 18px;
    border-radius: 5px;
    margin-bottom: 18px;
    font-size: 14px;
}

.alert-success { background: #d4edda; color: #155724; border-left: 4px solid #28a745; }
.alert-danger  { background: #f8d7da; color: #721c24; border-left: 4px solid #dc3545; }
.alert-info    { background: #d1ecf1; color: #0c5460; border-left: 4px solid #17a2b8; }

/* ============ INVOICE ============ */
.invoice {
    background: #fff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    max-width: 850px;
    margin: 0 auto;
}

.invoice-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    border-bottom: 3px solid #f39c12;
    padding-bottom: 20px;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.invoice-header h1 { color: #f39c12; font-size: 32px; }
.invoice-header .info { text-align: right; }
.invoice-header .info strong { font-size: 16px; }

.invoice-section {
    margin-bottom: 25px;
}

.invoice-section h3 {
    color: #34495e;
    margin-bottom: 10px;
    font-size: 16px;
    border-bottom: 1px solid #ecf0f1;
    padding-bottom: 5px;
}

.invoice-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.invoice-table th,
.invoice-table td {
    border: 1px solid #ecf0f1;
    padding: 10px 12px;
    text-align: left;
}

.invoice-table th {
    background: #f8f9fa;
    color: #2c3e50;
}

.invoice-total {
    text-align: right;
    font-size: 18px;
    color: #e67e22;
    font-weight: bold;
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.status-Menunggu     { background: #fff3cd; color: #856404; }
.status-Dikonfirmasi { background: #d1ecf1; color: #0c5460; }
.status-Diproses     { background: #cce5ff; color: #004085; }
.status-Selesai      { background: #d4edda; color: #155724; }
.status-Dibatalkan   { background: #f8d7da; color: #721c24; }
.status-Belum        { background: #f8d7da; color: #721c24; }
.status-Lunas        { background: #d4edda; color: #155724; }
.status-Sebagian     { background: #fff3cd; color: #856404; }

/* ============ INSTALL BOX ============ */
.install-box {
    max-width: 500px;
    margin: 80px auto;
    background: #fff;
    padding: 35px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    text-align: center;
}
.install-box ul {
    list-style: none;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 5px;
    margin: 15px 0;
    text-align: left;
}
.install-box code {
    background: #34495e;
    color: #f39c12;
    padding: 2px 8px;
    border-radius: 3px;
}

/* ============ FOOTER ============ */
.footer {
    background: #2c3e50;
    color: #ecf0f1;
    text-align: center;
    padding: 25px 20px;
    margin-top: 60px;
}

.footer p { margin: 4px 0; font-size: 14px; }
.footer .accent { color: #f39c12; }

/* ============ DETAIL PAGE ============ */
.detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 20px 0;
}
.detail-grid .item { padding: 10px 15px; background: #f8f9fa; border-left: 3px solid #f39c12; border-radius: 4px; }
.detail-grid .item small { color: #7f8c8d; display: block; }
.detail-grid .item strong { color: #2c3e50; }
@media (max-width:600px){
    .detail-grid { grid-template-columns: 1fr; }
}

/* ============ RESPONSIVE - GENERAL ============ */
@media (max-width: 768px) {
    .hero {
        padding: 60px 20px;
    }

    .hero h1 {
        font-size: 26px;
    }

    .hero p {
        font-size: 15px;
    }

    .hero .btn {
        display: block;
        margin: 8px auto;
        max-width: 220px;
        text-align: center;
    }

    .section {
        padding: 40px 18px;
    }

    .section-title {
        font-size: 22px;
    }

    .menu-grid {
        grid-template-columns: 1fr;
    }

    .features {
        grid-template-columns: 1fr 1fr;
    }

    .form-box {
        padding: 22px 16px;
    }

    .invoice {
        padding: 20px 14px;
    }

    .invoice-header {
        flex-direction: column;
    }

    .invoice-header .info {
        text-align: left;
    }
}

@media (max-width: 480px) {
    .features {
        grid-template-columns: 1fr;
    }

    .navbar .logo {
        font-size: 18px;
    }
}

/* Print invoice */
@media print {
    .navbar, .footer, .no-print { display: none !important; }
    body { background: #fff; }
    .invoice { box-shadow: none; padding: 0; }
}
