/* FILE: css/style.css */
/* Gaya utama untuk CytoZone PHP web app */
/* -------------------------------------- */

:root {
  --brand: #2563eb;
  --brand-dark: #1d4ed8;
  --bg: #f8fafc;
  --text: #1f2937;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Ubuntu, Cantarell, 'Noto Sans', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

/* Container umum */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* -------------------------------------- */
/* NAVBAR */
/* -------------------------------------- */

.nav {
  position: sticky;
  top: 0;
  background: #fff;
  border-bottom: 1px solid #e5e7eb;
  z-index: 50;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  color: var(--brand);
  text-decoration: none;
}

.logo {
  width: 28px;
  height: 28px;
  display: inline-block;
  background: radial-gradient(circle at center, #3b82f6 0%, #2563eb 60%, #1e40af 100%);
  border-radius: 50%;
}

.menu a {
  margin-left: 1rem;
  font-weight: 600;
  color: #374151;
  text-decoration: none;
}

.menu a:hover {
  color: var(--brand-dark);
}

/* Tombol umum */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  background: var(--brand);
  color: #fff;
  padding: 0.6rem 1.1rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
  transition: all 0.25s ease;
}

.btn:hover {
  background: var(--brand-dark);
}

.btn-light {
  background: #fff;
  color: var(--brand);
  border: 2px solid var(--brand);
}

.btn-light:hover {
  background: #eff6ff;
}

/* -------------------------------------- */
/* HERO SECTION */
/* -------------------------------------- */

.hero {
  background: linear-gradient(90deg, #3b82f6, #2563eb);
  color: #fff;
  padding: 4rem 0;
  text-align: center;
}

.hero h1 {
  font-size: 2.2rem;
  margin: 0;
}

.hero p {
  opacity: 0.95;
  margin: 0.75rem auto 0;
  max-width: 720px;
}

.actions {
  margin-top: 1rem;
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* -------------------------------------- */
/* SECTIONS & GRID */
/* -------------------------------------- */

.section {
  padding: 3rem 0;
}

.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(1, 1fr);
}

.grid.two {
  grid-template-columns: repeat(1, 1fr);
}

.grid.three {
  grid-template-columns: repeat(1, 1fr);
}

@media (min-width: 768px) {
  .grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .grid.two {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid.three {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* -------------------------------------- */
/* CARD & ELEMENTS */
/* -------------------------------------- */

.card {
  background: #fff;
  border-radius: 1rem;
  padding: 1.5rem;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.center {
  text-align: center;
}

.badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  background: #eff6ff;
  color: #1d4ed8;
}

.screenshot {
  margin-top: 1rem;
  height: 300px;
  border-radius: 0.75rem;
  background: linear-gradient(135deg, #e0f2fe, #bfdbfe);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
}

/* Header row di dashboard */
.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* List dan tabel */
.list {
  line-height: 1.9;
  padding-left: 1rem;
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.table th,
.table td {
  text-align: left;
  padding: 0.6rem;
  border-bottom: 1px solid #e5e7eb;
}

/* Overflow untuk tabel */
.overflow {
  overflow: auto;
}

/* -------------------------------------- */
/* IFRAME (Streamlit embed) */
/* -------------------------------------- */

.iframe-wrap {
  margin-top: 1rem;
  border-radius: 0.75rem;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  background: #111;
}

.iframe-wrap iframe {
  width: 100%;
  height: 70vh;
  background: #fff;
}

/* -------------------------------------- */
/* ALERTS & FORM */
/* -------------------------------------- */

.alert {
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
}

.alert-ok {
  background: #ecfdf5;
  color: #065f46;
  border: 1px solid #34d399;
}

.alert-error {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fca5a5;
}

.form {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.form input[type="file"] {
  padding: 0.5rem;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
}

.mt {
  margin-top: 1rem;
}

/* -------------------------------------- */
/* FOOTER */
/* -------------------------------------- */

.footer {
  background: #111827;
  color: #9ca3af;
  padding: 1.5rem 0;
  text-align: center;
  margin-top: 2rem;
}
