/*
Theme Name: ENCOT Meeting Attendance
Theme URI: https://example.com/
Author: OpenAI
Description: Custom WordPress theme for ENCOT Foundation meeting attendance capture, event-based reports, and PDF-ready downloads.
Version: 1.2.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
Text Domain: encot-attendance
*/

:root {
  --encot-primary: #197670;
  --encot-accent: #EE8227;
  --encot-white: #ffffff;
  --encot-bg: #f6fbfa;
  --encot-text: #183735;
  --encot-border: #d7e8e5;
  --encot-header-bg: #197670;
  --encot-header-text: #ffffff;
  --encot-header-subtitle: #eaf8f6;
  --encot-header-border: #EE8227;
  --encot-card-bg: #ffffff;
  --encot-card-title: #197670;
  --encot-field-bg: #ffffff;
  --encot-field-border: #bdd8d5;
  --encot-field-label: #0e4f4a;
  --encot-button-bg: #197670;
  --encot-button-text: #ffffff;
  --encot-button-hover: #EE8227;
  --encot-badge-bg: #EE8227;
  --encot-badge-text: #ffffff;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--encot-bg);
  color: var(--encot-text);
}

a { color: var(--encot-primary); text-decoration: none; }
a:hover { color: var(--encot-accent); }

.site-header {
  background: var(--encot-header-bg);
  color: var(--encot-header-text);
  padding: 18px 20px;
  border-bottom: 4px solid var(--encot-header-border);
}

.header-inner,
.site-content,
.site-footer-inner {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
}

.brand-wrap {
  display: flex;
  align-items: center;
  gap: 18px;
}

.brand-wrap img,
.encot-self-logo img {
  width: auto;
  max-height: 88px;
  max-width: 100%;
}

.brand-title {
  margin: 0;
  font-size: 1.7rem;
  line-height: 1.1;
  color: var(--encot-header-text);
}

.brand-subtitle {
  margin: 4px 0 0;
  color: var(--encot-header-subtitle);
}

.site-content {
  padding: 28px 0 40px;
}

.encot-shell {
  width: min(1200px, 100%);
  margin: 0 auto;
}

.encot-self-shell {
  width: min(860px, 100%);
}

.encot-card {
  background: var(--encot-card-bg);
  border: 1px solid var(--encot-border);
  border-radius: 20px;
  box-shadow: 0 14px 34px rgba(25, 118, 112, 0.08);
  padding: 22px;
  margin-bottom: 24px;
}

.encot-self-card {
  padding: 34px 42px;
}

.encot-self-header {
  text-align: center;
  margin-bottom: 28px;
}

.encot-self-title,
.encot-title {
  margin: 12px 0 8px;
  color: var(--encot-card-title);
  font-size: 2rem;
}

.encot-self-intro,
.encot-muted {
  color: #4a6663;
}

.encot-pill-row {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.encot-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 22px;
  min-width: 180px;
  border-radius: 999px;
  background: var(--encot-button-bg);
  color: var(--encot-button-text);
  font-weight: 700;
}

.encot-pill-accent {
  background: var(--encot-badge-bg);
  color: var(--encot-badge-text);
}

.encot-grid { display: grid; gap: 16px; }
.encot-grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.encot-grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.encot-grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.encot-field-grid {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.encot-field.full-span { grid-column: 1 / -1; }

label {
  display: block;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--encot-field-label);
  font-size: 15px;
}

input[type="text"],
input[type="date"],
input[type="password"],
input[type="tel"],
select,
textarea {
  width: 100%;
  border: 1px solid var(--encot-field-border);
  border-radius: 18px;
  background: var(--encot-field-bg);
  padding: 16px 18px;
  font-size: 15px;
  color: var(--encot-text);
}

input:focus,
select:focus,
textarea:focus {
  outline: 2px solid rgba(238,130,39,0.2);
  border-color: var(--encot-accent);
}

button,
.button,
input[type="submit"] {
  appearance: none;
  border: 0;
  border-radius: 16px;
  padding: 14px 22px;
  font-weight: 700;
  cursor: pointer;
  background: var(--encot-button-bg);
  color: var(--encot-button-text);
  transition: transform .15s ease, opacity .15s ease, background .2s ease;
}

button:hover,
.button:hover,
input[type="submit"]:hover {
  background: var(--encot-button-hover);
  transform: translateY(-1px);
  color: var(--encot-button-text);
}

.button.secondary {
  background: var(--encot-white);
  color: var(--encot-primary);
  border: 1px solid var(--encot-primary);
}

.notice-success,
.notice-error {
  padding: 14px 16px;
  border-radius: 12px;
  margin-bottom: 16px;
}
.notice-success { background: #ecfbf7; color: #165b56; border: 1px solid #b8e7d7; }
.notice-error { background: #fff1e6; color: #8c4f15; border: 1px solid #f7c89a; }

.encot-radio-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.encot-choice,
.encot-checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--encot-field-border);
  border-radius: 18px;
  background: var(--encot-field-bg);
  padding: 16px 18px;
  margin-bottom: 0;
  color: var(--encot-text);
  font-weight: 600;
}

.encot-choice input,
.encot-checkbox input {
  width: auto;
  min-width: auto;
  margin: 0;
}

.center-actions {
  justify-content: center;
}

.actions-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

.encot-reports-layout {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 24px;
  margin-top: 24px;
}

.encot-reports-nav {
  border: 1px solid var(--encot-border);
  border-radius: 18px;
  background: var(--encot-card-bg);
  padding: 18px;
  height: fit-content;
  position: sticky;
  top: 24px;
}

.encot-reports-nav h3 {
  margin-top: 0;
  color: var(--encot-card-title);
}

.encot-report-nav-item {
  display: block;
  border: 1px solid var(--encot-border);
  border-radius: 14px;
  padding: 14px;
  margin-bottom: 12px;
  background: #fbfdfd;
}

.encot-report-nav-item strong,
.encot-report-nav-item span,
.encot-report-nav-item small {
  display: block;
}

.encot-report-nav-item.active {
  border-color: var(--encot-accent);
  box-shadow: inset 0 0 0 1px var(--encot-accent);
}

.report-item {
  border: 1px solid var(--encot-border);
  border-left: 6px solid var(--encot-accent);
  border-radius: 18px;
  background: var(--encot-card-bg);
  padding: 18px;
}

.report-item h3 {
  margin: 0 0 8px;
  color: var(--encot-card-title);
}

.report-item-topbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

.report-meta {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 12px;
}

.report-meta span {
  display: block;
  background: #f5fbfa;
  border: 1px solid #ddeceb;
  border-radius: 10px;
  padding: 10px 12px;
}

.attendants-list-table-wrap,
.encot-report-sheet-table-wrap,
.encot-extra-table-wrap {
  overflow-x: auto;
}

.encot-simple-list-table,
.encot-report-sheet-table,
.encot-extra-table {
  width: 100%;
  border-collapse: collapse;
}

.encot-simple-list-table th,
.encot-simple-list-table td,
.encot-report-sheet-table th,
.encot-report-sheet-table td,
.encot-extra-table th,
.encot-extra-table td,
.encot-report-meta-table td {
  border: 1px solid #cedfdd;
  padding: 8px;
}

.encot-simple-list-table th,
.encot-extra-table th {
  background: var(--encot-primary);
  color: #fff;
  text-align: left;
}

.report-preview-heading {
  font-weight: 700;
  color: var(--encot-card-title);
  margin: 18px 0 12px;
}

.encot-report-sheet {
  border: 1px solid #cfd9d8;
  background: #fff;
  padding: 16px;
}

.encot-report-sheet-title {
  text-align: center;
  font-weight: 700;
  color: #111;
  margin-bottom: 10px;
}

.encot-report-meta-table,
.encot-report-sheet-table {
  width: 100%;
  border-collapse: collapse;
}

.encot-report-sheet-table th,
.encot-report-sheet-table td {
  font-size: 13px;
}

.encot-report-sheet-table .center,
.encot-extra-table td:first-child {
  text-align: center;
}

.encot-report-official-use {
  margin-top: 16px;
}

.encot-report-official-label {
  font-weight: 700;
  margin-bottom: 10px;
}

.encot-report-official-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.site-footer {
  border-top: 1px solid #dfeceb;
  background: var(--encot-card-bg);
}

.site-footer-inner {
  padding: 20px 0 28px;
  color: #4c6c68;
}

@media (max-width: 900px) {
  .encot-field-grid,
  .encot-reports-layout,
  .report-item-topbar,
  .encot-report-official-grid,
  .report-meta,
  .encot-radio-grid {
    grid-template-columns: 1fr;
    display: grid;
  }

  .encot-self-card {
    padding: 22px;
  }

  .encot-radio-grid {
    gap: 10px;
  }

  .encot-reports-nav {
    position: static;
  }
}


.site-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.site-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.site-nav-list li { margin: 0; }

.site-nav-list a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: 999px;
  color: var(--encot-header-text);
  border: 1px solid rgba(255,255,255,0.28);
  background: rgba(255,255,255,0.08);
  font-weight: 700;
}

.site-nav-list a:hover,
.site-nav-list .current-menu-item > a,
.site-nav-list .current_page_item > a,
.site-nav-list .current-menu-ancestor > a {
  background: var(--encot-accent);
  border-color: var(--encot-accent);
  color: var(--encot-white);
}

@media (max-width: 800px) {
  .site-header-row {
    align-items: flex-start;
  }

  .site-nav {
    width: 100%;
  }

  .site-nav-list {
    width: 100%;
  }
}
