@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  --primary: #0b7a45;
  --primary-dark: #065f2e;
  --primary-light: #eaf5ef;
  --accent: #e8a33d;
  --ink: #14211b;
  --muted: #5f6f67;
  --bg: #f6f9f7;
  --surface: #ffffff;
  --border: #e3ebe6;
  --radius: 16px;
  --shadow-sm: 0 1px 2px rgba(17, 34, 26, 0.05), 0 6px 18px rgba(17, 34, 26, 0.05);
  --shadow-md: 0 10px 34px rgba(17, 34, 26, 0.1);
  --shadow-lg: 0 24px 60px rgba(17, 34, 26, 0.14);
}

body {
  margin: 0;
  padding: 0;
  width: 100%;
  background: var(--bg);
  font-family: 'Plus Jakarta Sans', 'Segoe UI', system-ui, sans-serif;
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

/* ===== Intro (unused placeholder) ===== */
.introduction-section {
  width: 100%;
  height: 100vh;
}

.company-introduction {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  height: 100%;
  overflow: hidden;
}

.bg-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
}

/* ===== Carousel / Gallery ===== */
.carousel-container {
  width: 100%;
  margin: auto;
}

.carousel-inner img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

.gallery-container {
  max-width: 1400px;
  margin: 2rem auto;
  padding: 0 1.5rem;
}

.gallery {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  grid-auto-rows: 240px;
  gap: 1.1rem;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  cursor: pointer;
  box-shadow: var(--shadow-md);
}

.gallery-item-1 {
  grid-column: 1 / 2;
  grid-row: 1 / 3;
}

.gallery-item-2 {
  grid-column: 2 / 3;
  grid-row: 1 / 2;
}

.gallery-item-3 {
  grid-column: 2 / 3;
  grid-row: 2 / 3;
}

.gallery-item-4 {
  grid-column: 3 / 4;
  grid-row: 1 / 2;
}

.gallery-item-5 {
  grid-column: 3 / 4;
  grid-row: 2 / 3;
}

.gallery-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.gallery-item:hover .gallery-img {
  transform: scale(1.06);
}

.overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(5, 26, 17, 0.15) 0%, rgba(5, 26, 17, 0.55) 55%, rgba(5, 26, 17, 0.82) 100%);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1.25rem;
  color: #ffffff;
}

.category-tag {
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(4px);
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  align-self: flex-start;
}

.content {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.time {
  font-size: 0.8rem;
  opacity: 0.9;
}

.content .title {
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.3;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.55);
}

.gallery-item-1 .title {
  font-size: 1.45rem;
}

@media (max-width: 991.98px) {
  .gallery {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 220px;
  }

  .gallery-item-1 {
    grid-column: 1 / 3;
    grid-row: 1 / 2;
  }

  .gallery-item-2 {
    grid-column: 1 / 2;
    grid-row: 2 / 3;
  }

  .gallery-item-3 {
    grid-column: 2 / 3;
    grid-row: 2 / 3;
  }

  .gallery-item-4 {
    grid-column: 1 / 2;
    grid-row: 3 / 4;
  }

  .gallery-item-5 {
    grid-column: 2 / 3;
    grid-row: 3 / 4;
  }
}

@media (max-width: 640px) {
  .gallery {
    grid-template-columns: 1fr;
    grid-auto-rows: 220px;
  }

  .gallery-item-1,
  .gallery-item-2,
  .gallery-item-3,
  .gallery-item-4,
  .gallery-item-5 {
    grid-column: 1 / 2;
    grid-row: auto;
  }
}

/* ===== Cards & section headers ===== */
body .card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.pengumuman-section .card:hover,
.aktiviti-section .card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.section-header {
  color: var(--primary);
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
}

.inner-card {
  overflow: hidden;
}

.inner-card .card-img-top {
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.inner-card:hover {
  box-shadow: var(--shadow-md);
  border-color: rgba(11, 122, 69, 0.3);
}

/* ===== Video section ===== */
.video-section .card {
  width: 100%;
  height: auto;
}

.video-label {
  background: var(--primary);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 10;
}

.video-title {
  font-weight: 800;
  font-size: 1.2rem;
  color: #ffffff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.7);
  position: absolute;
  bottom: 1.25rem;
  left: 1rem;
  right: 1rem;
  line-height: 1.3;
  z-index: 10;
}

.video-meta {
  position: absolute;
  bottom: 1.9rem;
  right: 1rem;
  color: #ffffff;
  font-size: 0.75rem;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.7);
  display: flex;
  gap: 1rem;
  align-items: center;
  z-index: 10;
}

.btn-nav {
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  transition: all 0.25s ease;
}

.btn-nav:hover {
  background: var(--primary-light);
  color: var(--primary);
  border-color: var(--primary);
}

.video-thumb {
  border-radius: 12px;
  width: 100%;
  height: 170px;
  object-fit: cover;
}

.main-video {
  border-radius: 14px;
  width: 100%;
  height: 350px;
  object-fit: cover;
}

/* ===== Sidebar ===== */
.sidebar-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.sidebar-section:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.sidebar-section h3 {
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--ink);
  margin-bottom: 0;
}

.sidebar-section hr {
  border-color: var(--border);
  opacity: 1;
  margin: 0.25rem 0 1rem;
}

.sidebar-icon {
  color: var(--primary);
  font-size: 1.15rem;
}

/* ===== Waktu Solat widget ===== */
.waktu-solat {
  font-size: 0.85rem;
}

.ws-loading,
.ws-error {
  color: var(--muted);
  font-size: 0.8rem;
  text-align: center;
  padding: 0.75rem 0;
}

.ws-error {
  color: #b3443c;
}

.ws-date {
  color: var(--muted);
  font-size: 0.75rem;
  margin-bottom: 0.75rem;
  text-align: center;
}

.ws-next {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(600px 200px at 85% -30%, rgba(255, 255, 255, 0.14), transparent 60%),
    linear-gradient(135deg, #0b7a45 0%, #065f2e 100%);
  color: #ffffff;
  border-radius: 14px;
  padding: 0.9rem 1rem;
  text-align: center;
  box-shadow: 0 10px 22px rgba(11, 122, 69, 0.28);
}

.ws-next-label {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  opacity: 0.8;
}

.ws-next-name {
  font-size: 1.3rem;
  font-weight: 800;
  line-height: 1.25;
  margin-top: 0.15rem;
}

.ws-next-time {
  font-size: 1.05rem;
  font-weight: 700;
  opacity: 0.95;
}

.ws-next-countdown {
  margin-top: 0.4rem;
  display: inline-block;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  font-size: 0.75rem;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  padding: 0.25rem 0.8rem;
}

.ws-list {
  margin-top: 0.85rem;
}

.ws-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.42rem 0.6rem;
  border-radius: 10px;
  color: var(--ink);
}

.ws-row + .ws-row {
  border-top: 1px dashed var(--border);
}

.ws-row .ws-time {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  color: var(--muted);
}

.ws-row-next {
  background: var(--primary-light);
  color: var(--primary);
}

.ws-row-next .ws-time {
  color: var(--primary);
  font-weight: 800;
}

/* ===== Media gallery ===== */
.media-section {
  padding: 5rem 1.5rem;
  background: linear-gradient(160deg, #06271a 0%, #0b4d2e 55%, #0b7a45 100%);
}

.media-container {
  max-width: 1200px;
  margin: auto;
}

.media-title {
  color: #ffffff;
  font-size: 1.9rem;
  font-weight: 800;
  text-align: center;
  margin-bottom: 0.5rem;
}

.media-title::after {
  content: '';
  display: block;
  width: 56px;
  height: 4px;
  border-radius: 2px;
  background: var(--accent);
  margin: 0.75rem auto 0;
}

.media-subtitle {
  color: rgba(255, 255, 255, 0.7);
  text-align: center;
  margin-bottom: 2.5rem;
}

.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.1rem;
}

.media-item {
  overflow: hidden;
  border-radius: 16px;
  aspect-ratio: 4 / 3;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
}

.media-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.media-item:hover img {
  transform: scale(1.08);
}

/* ===== Corporate video ===== */
.video-container {
  background:
    radial-gradient(900px 400px at 20% -20%, rgba(255, 255, 255, 0.12), transparent 60%),
    linear-gradient(160deg, #06271a 0%, #0b7a45 100%);
  top: 0;
  margin: 0;
  padding: 6rem 1.5rem;
  width: 100%;
  box-sizing: border-box;
  text-align: center;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

.video-container .title {
  font-family: inherit;
  color: #ffffff;
  font-size: 2.4rem;
  font-weight: 800;
  margin: 0;
}

.play-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 84px;
  height: 84px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 50%;
  cursor: pointer;
  position: relative;
  transition: all 0.3s ease;
  animation: play-pulse 2.4s ease-in-out infinite;
}

.play-button i {
  color: #ffffff;
  font-size: 1.35rem;
  margin-left: 4px;
}

@keyframes play-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.35);
  }
  70% {
    box-shadow: 0 0 0 22px rgba(255, 255, 255, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0);
  }
}

.play-button:hover {
  background: var(--accent);
  transform: scale(1.06);
}

.modal button {
  position: absolute;
  top: 10px;
  right: 5px;
  margin-right: 10px;
  cursor: pointer;
  background-color: var(--surface);
  border: 1px solid var(--border);
}

.modal button:hover {
  color: var(--surface);
  background-color: var(--muted);
}

/* ===== Misc ===== */
.description {
  font-family: inherit;
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.8;
  color: var(--muted);
  margin: 0 auto 1.5rem;
  max-width: 720px;
}

.profile-button {
  background: var(--primary);
  color: #ffffff;
  border: none;
  border-radius: 999px;
  padding: 0.8rem 1.75rem;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 6px 16px rgba(11, 122, 69, 0.28);
}

.profile-button:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
}