/* =======================================================
   1. SETUP & VARIABEL WARNA (BRAND IDENTITY)
   ======================================================= */
:root {
    --green-ricargo: #009B4D;
    --green-dark: #007a3d;
    --yellow-ricargo: #FFDE00;
    --yellow-dark: #e6c800;
    --red-ricargo: #DA291C;
    --red-dark: #b0181d;
    --blue-admin: #1E88E5;
    
    --text-dark: #2d3436;
    --text-light: #636e72;
    --bg-light: #f4f9f4; 
    --bg-white: #ffffff;
    --shadow-soft: 0 10px 30px rgba(0, 155, 77, 0.08);
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Poppins', sans-serif; }
body { background: var(--bg-light); color: var(--text-dark); overflow-x: hidden; line-height: 1.6; }
.container { width: 90%; max-width: 1200px; margin: 0 auto; }
a { text-decoration: none; transition: 0.3s; } 
ul { list-style: none; }
html { scroll-behavior: smooth; }

/* =======================================================
   2. HEADER & NAVIGASI
   ======================================================= */
header {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky; top: 0; z-index: 1000;
}
.nav-container { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; }
.logo img { height: 50px; }
.nav-links { display: flex; gap: 20px; align-items: center; }
.nav-item { color: #333; font-weight: 500; transition: 0.3s; }
.nav-item:hover { color: var(--green-ricargo); }
.nav-btn-contact {
    background: var(--red-ricargo); color: #fff;
    padding: 8px 20px; border-radius: 5px; font-weight: 600;
}
.nav-btn-contact:hover { background: #b0181d; }
.menu-toggle { display: none; font-size: 1.5rem; cursor: pointer; }

/* =======================================================
   3. HERO SECTION
   ======================================================= */
.hero-section {
    height: 500px; width: 100%;
    background: url('hero-banner.jpg') center center/cover no-repeat;
    display: flex; align-items: center; position: relative;
}
.hero-section::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(90deg, rgba(0,155,77,0.95) 0%, rgba(0,155,77,0.8) 40%, rgba(0,0,0,0) 100%);
    z-index: 1;
}
.hero-content { position: relative; z-index: 2; display: flex; width: 100%; }
.hero-text-box { width: 50%; color: #fff; padding-right: 20px; }
.hero-text-box h1 {
    font-size: 3rem; font-weight: 800; line-height: 1.2; margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}
.hero-text-box h1 span { color: var(--yellow-ricargo); }
.hero-text-box p {
    font-size: 1.1rem; margin-bottom: 30px; line-height: 1.6;
    border-left: 4px solid var(--yellow-ricargo); padding-left: 20px;
}
.hero-buttons { display: flex; gap: 15px; }
.btn-primary {
    background: var(--yellow-ricargo); color: #000;
    padding: 12px 30px; border-radius: 50px; font-weight: 700;
}
.btn-primary:hover { background: #e6c800; }
.btn-outline {
    border: 2px solid #fff; color: #fff;
    padding: 12px 30px; border-radius: 50px; font-weight: 600;
}
.btn-outline:hover { background: #fff; color: var(--green-ricargo); }
.hero-spacer { width: 50%; }

/* =======================================================
   4. TRACKING SECTION (AREA PENTING)
   ======================================================= */
.tracking-section { margin-top: -50px; position: relative; z-index: 10; padding-bottom: 60px; }
.tracking-wrapper {
    background: #fff; padding: 40px; border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1); border-top: 5px solid var(--green-ricargo);
}
.tracking-header h2 { color: var(--green-ricargo); margin-bottom: 5px; }

/* --- A. TAB NAVIGASI (Cek Resi / Member) --- */
.tracking-tabs {
    display: flex; justify-content: center; gap: 10px;
    margin-bottom: 25px; border-bottom: 1px solid #eee; padding-bottom: 15px;
}
.tab-btn {
    background: #f1f3f5; border: none; padding: 10px 25px; border-radius: 50px;
    cursor: pointer; font-weight: 600; color: #888; transition: 0.3s;
    display: flex; align-items: center; gap: 8px; font-size: 0.9rem;
}
.tab-btn:hover:not(.active) { background: #e9ecef; color: #555; }
.tab-btn.active {
    background: var(--blue-admin); color: #fff;
    box-shadow: 0 4px 10px rgba(30, 136, 229, 0.3);
}

/* --- B. FORM INPUT (Resi & Login) --- */
.tracking-form { display: flex; gap: 10px; align-items: center; }
.input-group { position: relative; width: 100%; }
.input-group i { 
    position: absolute; left: 15px; top: 50%; transform: translateY(-50%); 
    color: var(--blue-admin); font-size: 1rem;
}

.tracking-form input {
    width: 100%; 
    padding: 12px 15px 12px 45px; /* Padding kiri besar untuk icon */
    border: 2px solid #eee; border-radius: 8px;
    font-size: 0.95rem; outline: none; transition: 0.3s;
    /* PENTING: Text Transform Uppercase DIHAPUS agar password aman */
}
.tracking-form input:focus { border-color: var(--blue-admin); }
.tracking-form input::placeholder { color: #aaa; opacity: 0.7; }

/* Khusus Kolom Resi (Tetap Kapital) */
#resiInput { text-transform: uppercase; }

/* Tombol Submit */
.tracking-form button {
    padding: 12px 25px; border-radius: 8px; border: none; font-weight: 600; cursor: pointer; color: white;
    transition: 0.3s; white-space: nowrap;
}
#trackingForm button { background: var(--green-ricargo); } /* Tombol Cek Resi Hijau */
#memberForm button { background: var(--blue-admin); } /* Tombol Login Biru */
.tracking-form button:hover { opacity: 0.9; transform: translateY(-2px); box-shadow: 0 4px 10px rgba(0,0,0,0.15); }

/* =======================================================
   5. HASIL TRACKING (TABEL & HISTORY)
   ======================================================= */
.tracking-result { margin-top: 25px; animation: slideUp 0.5s ease; }

/* Style Tabel agar Responsive di HP */
.table-responsive { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }

/* Tombol Detail (Accordion) */
.btn-detail {
    background: #f0f0f0; border: none; padding: 5px 12px; border-radius: 5px;
    font-size: 0.75rem; cursor: pointer; color: #555; margin-top: 5px; transition: 0.3s;
    display: inline-flex; align-items: center; gap: 5px;
}
.btn-detail:hover { background: #ddd; color: #333; }

/* Baris Detail (Awalnya Sembunyi) */
.detail-row { background-color: #fcfcfc; border-bottom: 2px solid #eee; }

/* Timeline History (Garis Waktu) */
.mini-timeline {
    padding: 15px 20px; border-left: 3px solid #eee; margin: 10px 0 10px 15px;
}
.mini-item { position: relative; padding-left: 20px; margin-bottom: 12px; }
.mini-item::before {
    content: ''; position: absolute; left: -20px; top: 6px;
    width: 8px; height: 8px; background: #ccc; border-radius: 50%; border: 2px solid #fff;
}
/* Titik Aktif (Paling Atas) */
.mini-item.active::before {
    background: var(--blue-admin); width: 10px; height: 10px; left: -21px;
}
.mini-date { font-size: 0.75rem; font-weight: bold; color: var(--blue-admin); }
.mini-desc { font-size: 0.85rem; color: #555; line-height: 1.4; }

/* Animasi */
@keyframes slideUp { from { opacity:0; transform:translateY(20px); } to { opacity:1; transform:translateY(0); } }
@keyframes fadeIn { from{opacity:0;} to{opacity:1;} }

/* =======================================================
   6. KONTEN LAIN (SERVICES, ABOUT, CONTACT)
   ======================================================= */
.services-section { padding: 80px 0; background: var(--bg-light); }
.section-title h2 { color: var(--text-dark); font-size: 2.2rem; font-weight: 800; }
.section-title .line { 
    width: 80px; height: 5px; margin: 15px auto; 
    background: linear-gradient(90deg, var(--green-ricargo), var(--yellow-ricargo)); border-radius: 5px;
}
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; margin-top: 40px; }
.service-card {
    background: var(--bg-white); padding: 40px 30px; border-radius: 20px;
    text-align: center; transition: 0.4s; box-shadow: var(--shadow-soft);
    position: relative; overflow: hidden;
}
.service-card::after {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 5px;
    background: linear-gradient(90deg, var(--green-ricargo) 33%, var(--yellow-ricargo) 33%, var(--yellow-ricargo) 66%, var(--red-ricargo) 66%);
    opacity: 0; transition: 0.3s;
}
.service-card:hover { transform: translateY(-10px); }
.service-card:hover::after { opacity: 1; }
.icon-box { 
    width: 80px; height: 80px; margin: 0 auto 25px;
    background: rgba(0, 155, 77, 0.1); color: var(--green-ricargo);
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-size: 2rem; transition: 0.4s;
}
.service-card h3 { font-size: 1.3rem; margin-bottom: 15px; color: var(--text-dark); }
.service-card p { color: var(--text-light); font-size: 0.95rem; }

/* ABOUT & CONTACT GRID */
.about-section { padding: 80px 0; background: #f9f9f9; }
.about-grid, .contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: center; }
.about-text h2 { color: var(--green-ricargo); margin-bottom: 20px; font-weight: 800; border-left: 5px solid var(--yellow-ricargo); padding-left: 15px; }
.about-img img { width: 100%; border-radius: 10px; box-shadow: 0 10px 20px rgba(0,0,0,0.1); }

.contact-section { padding: 80px 0; background: var(--green-ricargo); color: #fff; }
.contact-info-box h2 { color: var(--yellow-ricargo); margin-bottom: 10px; }
.contact-form-box { background: #fff; padding: 30px; border-radius: 10px; color: #333; }
.contact-form-box input, .contact-form-box textarea { width: 100%; padding: 12px; margin-bottom: 15px; border: 1px solid #ddd; border-radius: 5px; }
.btn-wa { width: 100%; background: #25D366; color: #fff; border: none; padding: 12px; border-radius: 5px; font-weight: 700; cursor: pointer; }

/* FOOTER */
footer { background: #111; color: #aaa; text-align: center; padding: 20px; margin-top: auto; }

/* =======================================================
   7. FLOATING ELEMENTS & RESPONSIVE
   ======================================================= */
.floating-wa {
    position: fixed; bottom: 30px; right: 30px;
    width: 60px; height: 60px;
    background-color: #25d366; color: white;
    border-radius: 50%; text-align: center;
    font-size: 35px; line-height: 60px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3); z-index: 9999; transition: 0.3s;
}
.floating-wa:hover { background-color: #128C7E; transform: scale(1.1); }

@media (max-width: 768px) {
    .nav-links { display: none; } .menu-toggle { display: block flek; }
    .hero-section { height: auto; padding: 100px 0 50px; }
    .hero-text-box { width: 100%; text-align: center; padding: 0; }
    .hero-section::before { background: rgba(0,155,77,0.9); }
    .services-grid, .about-grid, .contact-grid { grid-template-columns: 1fr; }
    
    /* Responsive Form & Table */
    .tracking-form { flex-direction: column; }
    .input-group, .tracking-form button { width: 100%; }
    .hero-spacer { display: none; }
    .about-img { order: -1; }
}