/* Base */
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: #f4f6f3;
  color: #2e2e2e;
}

/* Header/Nav */
.site-header {
  background: #1f4d2e;
  color: #fff;
}

.nav-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: #ffffff;
  text-decoration: none;
  padding-right: 18px;
  border-right: 2px solid rgba(255,255,255,0.25);
}

.brand-logo {
  height: 26px;
  width: auto;
  display: block;
}

.brand:hover {
  opacity: 0.9;
}

.nav a {
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  font-weight: 600;
  margin-left: 16px;
}

.nav a:hover {
  color: #ffffff;
}

/* Page container */
.page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 18px 12px 40px;
}

/* Footer */
.site-footer {
  margin-top: 40px;
  padding: 18px 12px;
  text-align: center;
  font-size: 14px;
  color: #666;
}

/* Weather page title*/
.weather-titlebar {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin: 6px 0 12px;
  flex-wrap: wrap; /* allows wrap on small screens */
}

.weather-titlebar h1 {
  margin: 0;
  font-size: 22px;
  color: #1f4d2e;
}

.weather-titlebar .subtitle {
  font-size: 14px;
  color: #555;
}

/* Dashboard grid */
.grid {
  display: grid;
  grid-template-columns: 1fr;  /* mobile */
  gap: 10px;
}

/* Desktop = always 2x2 */
@media (min-width: 900px) {
  .grid {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    height: calc(100vh - 170px); /* fits under header/footer */
  }
}

/* Frame container */
.cell {
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}

/* Header above each iframe */
.cell-header {
  padding: 8px 10px;
  background: #e9eee9;
  border-bottom: 1px solid rgba(0,0,0,0.08);
  font-size: 14px;
}

/* Iframe takes remaining space */
.cell-body {
  flex: 1;
  min-height: 0;
}

iframe {
  width: 100%;
  height: 100%;
  border: 0;
}


@media (min-width: 900px) {
  .cell-body {
    height: 70vh;        /* more screen usage on desktop */
    min-height: 520px;
  }
}

iframe {
  width: 100%;
  height: 100%;
  border: 0;
  background: #fff;
}

/*Index content*/
.tagline {
    margin: 10px 0 6px;
    font-weight: 600;
    color: #1f4d2e;
}

.subline {
    margin-top: 8px;
    font-size: 15px;
    color: #555;
}

.coming-soon {
    margin-top: 18px;
    font-size: 20px;
    color: #777;
}

.hero {
    display: flex;
    flex-direction: column; /* mobile first */
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    gap: 30px;
    text-align: center;
}

.hero img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.hero-text {
    max-width: 520px;
}

/* Desktop side-by-side layout */
@media (min-width: 900px) {
    .hero {
        flex-direction: row;
        text-align: left;
        align-items: center;
    }

    .hero-text {
        flex: 1;
    }

    .hero img {
        flex: 1;
        max-width: 600px;
    }
}

/* View Documents */
.plans-list {
  background: #fff;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 10px;
  overflow: hidden;
}

.plan-row {
  display: block;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(0,0,0,0.06);
  text-decoration: none;
  color: #1f4d2e;
  font-weight: 700;
}

.plan-row:last-child {
  border-bottom: none;
}

.plan-row:hover {
  background: #f1f5f2;
}

.viewer-layout {
  display: flex;
  gap: 10px;
  height: calc(100vh - 170px);
}

/* Narrower sidebar */
.viewer-sidebar {
  width: 200px;              /* was ~280 */
  background: #fff;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Smaller header area */
.viewer-sidebar-top {
  padding: 8px 10px 6px;
  background: #e9eee9;
  border-bottom: 1px solid rgba(0,0,0,0.08);
}

.viewer-title {
  font-weight: 800;
  font-size: 13px;
  color: #1f4d2e;
  margin-bottom: 4px;
}

.viewer-back {
  font-size: 12px;
}

/* Sheet list */
.viewer-nav {
  padding: 4px;
  overflow: auto;
  flex: 1;
}

.viewer-link {
  display: block;
  padding: 6px 8px;          /* tighter rows */
  border-radius: 6px;
  text-decoration: none;
  color: #1f4d2e;
  font-weight: 700;
  font-size: 12px;           /* smaller text */
  line-height: 1.25;
}

.viewer-link:hover { background: #f1f5f2; }

.viewer-link.active {
  background: #1f4d2e;
  color: #fff;
}


.viewer-main {
  flex: 1;
  background: #fff;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.viewer-main-bar {
  padding: 10px 12px;
  background: #f4f6f3;
  border-bottom: 1px solid rgba(0,0,0,0.08);
  font-weight: 800;
  color: #1f4d2e;
}

.viewer-iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

/* Mobile: stack sidebar above viewer */
@media (max-width: 900px) {
  .viewer-layout { flex-direction: column; height: auto; }
  .viewer-sidebar { width: auto; max-height: 260px; }
  .viewer-main { height: 75vh; }
}

/* Button shown only on mobile */
.index-toggle {
  display: none;
  border: 0;
  background: #1f4d2e;
  color: #fff;
  font-weight: 800;
  padding: 8px 10px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
}

.viewer-main-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: #f4f6f3;
  border-bottom: 1px solid rgba(0,0,0,0.08);
}

.zoom-controls {
  display: flex;
  gap: 8px;
}

.zoom-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 36px;
  border-radius: 10px;
  background: #1f4d2e;
  color: #fff;
  text-decoration: none;
  font-weight: 900;
  font-size: 22px;
  line-height: 1;
}

.zoom-btn:active { transform: scale(0.98); }

.viewer-main-title {
  font-weight: 800;
  color: #1f4d2e;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}


/* Mobile behavior: sidebar collapses */
@media (max-width: 900px) {
  .viewer-layout {
    flex-direction: column;
    height: auto;
  }

  .index-toggle {
    display: inline-block; /* show button on phones */
  }

  .viewer-sidebar {
    width: auto;
    max-height: 0;         /* collapsed */
    border-radius: 10px;
    overflow: hidden;
    transition: max-height 0.25s ease;
  }

  .viewer-sidebar.open {
    max-height: 60vh;      /* expanded */
  }

  .viewer-main {
    height: 78vh;          /* map/pdf gets most space */
  }

  /* Optional: make the sheet list easier to tap */
  .viewer-link {
    font-size: 13px;
    padding: 10px 10px;
  }
}

.viewer-iframe {
  width: 100%;
  height: 100%;
  border: 0;
  touch-action: manipulation;
}

.greenbtn{
  background:#1f4d2e;
  color:white;
  border:none;
  padding:10px 16px;
  border-radius:10px;
  font-weight:800;
  font-size:15px;
  cursor:pointer;
}

.greenbtn:hover{
  background:#2c6a40;
}
