/* ============================================
   CLEVELAND PTA SNACK SHACK
   ============================================ */

:root {
  --navy: #102f4b;
  --navy-dark: #09243b;
  --red: #c92732;
  --red-dark: #a91e27;
  --green: #24945f;
  --green-light: #e7f6ee;
  --yellow: #a96b00;
  --yellow-light: #fff4d9;
  --cream: #fffdf9;
  --background: #f2f7fa;
  --white: #ffffff;
  --text: #102f4b;
  --muted: #6c8091;
  --border: #d8e3eb;
  --shadow: 0 8px 24px rgba(16, 47, 75, 0.08);
  --radius: 20px;
}


/* ============================================
   RESET
   ============================================ */

* {
  box-sizing: border-box;
}

html {
  margin: 0;
  padding: 0;
}

body {
  margin: 0;
  padding: 0;

  font-family:
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    Helvetica,
    Arial,
    sans-serif;

  background:
    linear-gradient(
      135deg,
      #f5fafc 0%,
      #edf4f8 100%
    );

  color: var(--text);

  min-height: 100vh;
}


button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.hidden {
  display: none !important;
}


/* ============================================
   LOGIN
   ============================================ */

#login-screen {
  min-height: 100vh;

  display: flex;

  align-items: center;
  justify-content: center;

  padding: 30px;
}

.login-card {
  width: 100%;
  max-width: 520px;

  background: var(--white);

  border-radius: 28px;

  padding: 55px 45px;

  text-align: center;

  box-shadow:
    0 20px 60px rgba(16, 47, 75, 0.12);
}

.login-icon {
  font-size: 58px;
  line-height: 1;

  margin-bottom: 15px;
}

.login-card h1 {
  margin: 0;

  font-size: clamp(42px, 7vw, 64px);

  font-weight: 800;

  letter-spacing: -2px;

  color: var(--navy);
}

.login-card p {
  margin: 10px 0;

  font-size: 21px;

  color: var(--navy);
}

.login-card .login-subtitle {
  margin-top: 25px;

  font-size: 25px;

  font-weight: 700;
}

.small-text {
  font-size: 15px !important;

  color: var(--muted) !important;

  margin-top: 18px !important;
}


/* ============================================
   BUTTONS
   ============================================ */

.primary-btn {
  border: none;

  background: var(--red);

  color: white;

  border-radius: 12px;

  padding: 14px 24px;

  font-weight: 700;

  transition:
    transform 0.15s ease,
    background 0.15s ease,
    box-shadow 0.15s ease;
}

.primary-btn:hover {
  background: var(--red-dark);

  transform: translateY(-1px);

  box-shadow:
    0 5px 14px rgba(201, 39, 50, 0.25);
}

.primary-btn:active {
  transform: translateY(0);
}

.login-card .primary-btn {
  margin-top: 20px;

  font-size: 18px;

  padding: 15px 32px;
}


/* ============================================
   APP HEADER
   ============================================ */

.app-header {
  background:
    linear-gradient(
      135deg,
      var(--navy-dark),
      var(--navy)
    );

  color: white;

  padding:
    30px
    max(30px, calc((100vw - 1180px) / 2));

  display: flex;

  align-items: center;

  justify-content: space-between;

  gap: 25px;

  box-shadow:
    0 4px 18px rgba(9, 36, 59, 0.16);
}

.app-header h1 {
  margin: 0;

  font-size: clamp(38px, 5vw, 58px);

  line-height: 1;

  font-weight: 800;

  letter-spacing: -2px;
}

.app-header p {
  margin: 8px 0 0;

  font-size: 16px;

  font-weight: 700;

  letter-spacing: 1.5px;

  text-transform: uppercase;

  opacity: 0.9;
}

.app-header span {
  display: block;

  margin-top: 4px;

  font-size: 17px;

  font-weight: 600;

  color: #dce8f1;
}

.logout-btn {
  border: 1px solid rgba(255, 255, 255, 0.3);

  background: rgba(255, 255, 255, 0.1);

  color: white;

  border-radius: 12px;

  padding: 12px 20px;

  font-weight: 700;

  white-space: nowrap;

  transition:
    background 0.15s ease,
    transform 0.15s ease;
}

.logout-btn:hover {
  background: rgba(255, 255, 255, 0.18);

  transform: translateY(-1px);
}


/* ============================================
   MAIN CONTAINER
   ============================================ */

.app-container {
  width: min(1180px, calc(100% - 40px));

  margin: 32px auto 60px;
}


/* ============================================
   DAILY DASHBOARD
   ============================================ */

.daily-dashboard {
  background: white;

  border-radius: var(--radius);

  padding: 25px;

  margin-bottom: 20px;

  box-shadow: var(--shadow);
}

.dashboard-heading {
  display: flex;

  align-items: center;

  justify-content: space-between;

  gap: 20px;

  margin-bottom: 20px;
}

.dashboard-eyebrow {
  margin: 0 0 4px;

  color: var(--red);

  font-size: 12px;

  font-weight: 900;

  letter-spacing: 1.5px;
}

.dashboard-heading h2,
.section-heading h2 {
  margin: 0;

  color: var(--navy);

  font-size: 27px;

  font-weight: 800;

  letter-spacing: -0.5px;
}

.dashboard-date {
  color: var(--muted);

  font-size: 14px;

  font-weight: 700;

  white-space: nowrap;
}

.dashboard-stats {
  display: grid;

  grid-template-columns:
    repeat(3, minmax(0, 1fr));

  gap: 14px;
}

.stat-card {
  display: flex;

  align-items: center;

  gap: 14px;

  padding: 17px;

  border-radius: 16px;

  background: #f6f9fb;

  border: 1px solid var(--border);
}

.stat-icon {
  width: 46px;

  height: 46px;

  display: flex;

  align-items: center;

  justify-content: center;

  flex-shrink: 0;

  border-radius: 13px;

  background: white;

  font-size: 23px;

  box-shadow:
    0 3px 8px rgba(16, 47, 75, 0.06);
}

.stat-card strong {
  display: block;

  color: var(--navy);

  font-size: 27px;

  line-height: 1;

  font-weight: 850;
}

.stat-card > div > span {
  display: block;

  margin-top: 5px;

  color: var(--muted);

  font-size: 12px;

  font-weight: 700;

  text-transform: uppercase;

  letter-spacing: 0.7px;
}


/* ============================================
   ADD STUDENT
   ============================================ */

.add-student-btn {
  width: 100%;

  border: none;

  background: var(--red);

  color: white;

  border-radius: 16px;

  padding: 17px 24px;

  margin-bottom: 18px;

  font-size: 19px;

  font-weight: 800;

  box-shadow:
    0 6px 16px rgba(201, 39, 50, 0.16);

  transition:
    transform 0.15s ease,
    background 0.15s ease,
    box-shadow 0.15s ease;
}

.add-student-btn:hover {
  background: var(--red-dark);

  transform: translateY(-1px);

  box-shadow:
    0 8px 20px rgba(201, 39, 50, 0.22);
}


/* ============================================
   SEARCH
   ============================================ */

.search-container {
  background: white;

  border-radius: var(--radius);

  padding: 20px;

  margin-bottom: 24px;

  box-shadow: var(--shadow);
}

#search-input {
  width: 100%;

  border: 2px solid var(--border);

  border-radius: 14px;

  background: white;

  color: var(--text);

  padding: 16px 18px;

  font-size: 18px;

  outline: none;

  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}

#search-input:focus {
  border-color: var(--navy);

  box-shadow:
    0 0 0 4px rgba(16, 47, 75, 0.08);
}

#search-input::placeholder {
  color: #8a9aaa;
}


/* ============================================
   STUDENT GRID
   ============================================ */

#student-list {
  display: grid;

  grid-template-columns:
    repeat(2, minmax(0, 1fr));

  gap: 20px;
}


/* ============================================
   STUDENT CARD
   ============================================ */

.student-card {
  background: white;

  border-radius: var(--radius);

  padding: 24px;

  box-shadow: var(--shadow);

  border: 1px solid rgba(216, 227, 235, 0.7);

  display: grid;

  grid-template-columns: 1fr auto;

  column-gap: 18px;

  row-gap: 20px;

  align-items: start;

  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

.student-card:hover {
  transform: translateY(-2px);

  box-shadow:
    0 12px 28px rgba(16, 47, 75, 0.11);
}

.student-info h2 {
  margin: 0;

  font-size: 23px;

  line-height: 1.15;

  font-weight: 800;

  color: var(--navy);

  letter-spacing: -0.4px;
}

.student-info p {
  margin: 6px 0 0;

  font-size: 15px;

  font-weight: 600;

  color: var(--muted);
}


/* ============================================
   BALANCE
   ============================================ */

.student-balance {
  min-width: 92px;

  padding: 10px 14px;

  border-radius: 15px;

  background: var(--green-light);

  color: var(--green);

  text-align: center;
}

.student-balance strong {
  display: block;

  font-size: 32px;

  line-height: 1;

  font-weight: 850;
}

.student-balance span {
  display: block;

  margin-top: 5px;

  font-size: 9px;

  line-height: 1.1;

  text-transform: uppercase;

  letter-spacing: 0.8px;

  font-weight: 900;
}

.student-balance.medium-balance {
  background: var(--yellow-light);

  color: var(--yellow);
}

.student-balance.low-balance {
  background: #fde8e8;

  color: var(--red);
}

.student-balance.zero-balance {
  background: #f5e1e1;

  color: var(--red);
}


/* ============================================
   PUNCH BUTTONS
   ============================================ */

.punch-buttons {
  grid-column: 1 / -1;

  display: grid;

  grid-template-columns:
    repeat(4, minmax(0, 1fr));

  gap: 10px;
}

.punch-btn {
  border: none;

  background: var(--navy);

  color: white;

  border-radius: 12px;

  padding: 14px 8px;

  min-height: 50px;

  font-size: 17px;

  font-weight: 800;

  transition:
    background 0.15s ease,
    transform 0.1s ease;
}

.punch-btn:hover:not(:disabled) {
  background: var(--navy-dark);

  transform: translateY(-1px);
}

.punch-btn:active:not(:disabled) {
  transform: translateY(0);
}

.punch-btn:disabled {
  opacity: 0.35;

  cursor: not-allowed;
}


/* ============================================
   TRANSACTION HISTORY
   ============================================ */

.transactions-section {
  background: white;

  border-radius: var(--radius);

  margin-top: 28px;

  padding: 25px;

  box-shadow: var(--shadow);
}

.section-heading {
  margin-bottom: 16px;
}

.transaction-list {
  width: 100%;
}

.transaction-row {
  display: flex;

  align-items: center;

  justify-content: space-between;

  gap: 20px;

  padding: 15px 4px;

  border-top: 1px solid var(--border);
}

.transaction-person strong {
  display: block;

  color: var(--navy);

  font-size: 16px;
}

.transaction-person span {
  display: block;

  margin-top: 3px;

  color: var(--muted);

  font-size: 12px;
}

.transaction-details {
  text-align: right;

  white-space: nowrap;
}

.transaction-details strong {
  display: block;

  color: var(--red);

  font-size: 18px;
}

.transaction-details span {
  display: block;

  margin-top: 2px;

  color: var(--muted);

  font-size: 12px;
}

.transaction-empty {
  padding: 25px 10px;

  text-align: center;

  color: var(--muted);

  font-size: 15px;

  font-weight: 600;

  border-top: 1px solid var(--border);
}


/* ============================================
   EMPTY STATE
   ============================================ */

.empty-state {
  grid-column: 1 / -1;

  background: white;

  border-radius: var(--radius);

  padding: 55px 20px;

  text-align: center;

  box-shadow: var(--shadow);

  color: var(--muted);
}

.empty-state div {
  font-size: 42px;

  margin-bottom: 10px;
}

.empty-state p {
  margin: 0;

  font-size: 18px;

  font-weight: 600;
}


/* ============================================
   MODALS
   ============================================ */

.modal {
  position: fixed;

  inset: 0;

  z-index: 1000;

  background:
    rgba(9, 36, 59, 0.55);

  backdrop-filter: blur(4px);

  display: flex;

  align-items: center;

  justify-content: center;

  padding: 20px;
}

.modal-card {
  position: relative;

  width: 100%;

  max-width: 480px;

  background: white;

  border-radius: 24px;

  padding: 32px;

  box-shadow:
    0 25px 70px rgba(0, 0, 0, 0.2);
}

.modal-card h2 {
  margin: 0;

  color: var(--navy);

  font-size: 28px;

  font-weight: 800;
}

.modal-subtitle {
  margin: 7px 0 25px;

  color: var(--muted);

  font-size: 15px;
}

.modal-card label {
  display: block;

  margin: 18px 0 7px;

  color: var(--navy);

  font-size: 14px;

  font-weight: 800;
}

.modal-card input,
.modal-card select {
  width: 100%;

  border: 2px solid var(--border);

  border-radius: 12px;

  background: white;

  color: var(--text);

  padding: 13px 14px;

  font-size: 16px;

  outline: none;
}

.modal-card input:focus,
.modal-card select:focus {
  border-color: var(--navy);

  box-shadow:
    0 0 0 4px rgba(16, 47, 75, 0.08);
}

.modal-card .primary-btn {
  width: 100%;

  margin-top: 25px;

  font-size: 17px;
}

.modal-close {
  position: absolute;

  top: 14px;

  right: 16px;

  width: 38px;

  height: 38px;

  border: none;

  border-radius: 50%;

  background: #f1f5f8;

  color: var(--navy);

  font-size: 25px;

  line-height: 1;

  cursor: pointer;
}

.modal-close:hover {
  background: #e5edf2;
}


/* ============================================
   CONFIRMATION
   ============================================ */

#confirmation-message {
  margin: 20px 0;

  color: var(--muted);

  font-size: 17px;

  line-height: 1.55;
}

.confirmation-buttons {
  display: grid;

  grid-template-columns:
    1fr 1fr;

  gap: 12px;

  margin-top: 25px;
}

.secondary-btn {
  border: 2px solid var(--border);

  background: white;

  color: var(--navy);

  border-radius: 12px;

  padding: 13px 18px;

  font-weight: 700;

  cursor: pointer;
}

.secondary-btn:hover {
  background: #f5f8fa;
}


/* ============================================
   MOBILE
   ============================================ */

@media (max-width: 800px) {

  .app-header {
    padding: 24px 20px;

    align-items: flex-start;
  }

  .app-header h1 {
    font-size: 40px;
  }

  .app-header p {
    font-size: 13px;
  }

  .app-header span {
    font-size: 15px;
  }

  .logout-btn {
    padding: 10px 14px;

    font-size: 14px;
  }

  .app-container {
    width: calc(100% - 24px);

    margin-top: 20px;
  }

  .dashboard-stats {
    grid-template-columns: 1fr;
  }

  #student-list {
    grid-template-columns: 1fr;
  }

}


/* ============================================
   SMALL MOBILE
   ============================================ */

@media (max-width: 520px) {

  #login-screen {
    padding: 16px;
  }

  .login-card {
    padding: 40px 24px;

    border-radius: 22px;
  }

  .login-card h1 {
    font-size: 46px;
  }

  .login-card p {
    font-size: 18px;
  }

  .app-header {
    padding: 20px 16px;

    flex-direction: column;
  }

  .app-header h1 {
    font-size: 36px;
  }

  .logout-btn {
    align-self: stretch;
  }

  .app-container {
    width: calc(100% - 20px);

    margin-top: 15px;
  }

  .daily-dashboard {
    padding: 19px;
  }

  .dashboard-heading {
    align-items: flex-start;

    flex-direction: column;

    gap: 8px;
  }

  .dashboard-heading h2 {
    font-size: 24px;
  }

  .dashboard-date {
    font-size: 12px;
  }

  .stat-card {
    padding: 14px;
  }

  .search-container {
    padding: 16px;
  }

  .student-card {
    padding: 18px;

    grid-template-columns:
      1fr auto;
  }

  .student-info h2 {
    font-size: 20px;
  }

  .student-balance {
    min-width: 76px;

    padding: 9px 10px;
  }

  .student-balance strong {
    font-size: 27px;
  }

  .punch-buttons {
    gap: 7px;
  }

  .punch-btn {
    padding: 13px 5px;

    font-size: 16px;
  }

  .transactions-section {
    padding: 19px;
  }

  .transaction-row {
    gap: 10px;
  }

  .transaction-person strong {
    font-size: 15px;
  }

  .transaction-details strong {
    font-size: 16px;
  }

  .modal-card {
    padding: 26px 20px;
  }

}}


/* ============================================
   LOGIN
   ============================================ */

#login-screen {
  min-height: 100vh;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 30px;
}

.login-card {
  width: 100%;
  max-width: 520px;

  background: var(--white);

  border-radius: 28px;

  padding: 55px 45px;

  text-align: center;

  box-shadow:
    0 20px 60px rgba(16, 47, 75, 0.12);
}

.login-icon {
  font-size: 58px;
  line-height: 1;
  margin-bottom: 15px;
}

.login-card h1 {
  margin: 0;

  font-size: clamp(42px, 7vw, 64px);

  font-weight: 800;

  letter-spacing: -2px;

  color: var(--navy);
}

.login-card p {
  margin: 10px 0;

  font-size: 21px;

  color: var(--navy);
}

.login-card .login-subtitle {
  margin-top: 25px;

  font-size: 25px;

  font-weight: 700;
}

.small-text {
  font-size: 15px !important;
  color: var(--muted) !important;
  margin-top: 18px !important;
}


/* ============================================
   BUTTONS
   ============================================ */

.primary-btn {
  border: none;

  background: var(--red);

  color: white;

  border-radius: 12px;

  padding: 14px 24px;

  font-weight: 700;

  transition:
    transform 0.15s ease,
    background 0.15s ease,
    box-shadow 0.15s ease;
}

.primary-btn:hover {
  background: var(--red-dark);

  transform: translateY(-1px);

  box-shadow:
    0 5px 14px rgba(201, 39, 50, 0.25);
}

.primary-btn:active {
  transform: translateY(0);
}

.login-card .primary-btn {
  margin-top: 20px;

  font-size: 18px;

  padding: 15px 32px;
}


/* ============================================
   APP HEADER
   ============================================ */

.app-header {
  background:
    linear-gradient(
      135deg,
      var(--navy-dark),
      var(--navy)
    );

  color: white;

  padding:
    30px
    max(30px, calc((100vw - 1180px) / 2));

  display: flex;

  align-items: center;

  justify-content: space-between;

  gap: 25px;

  box-shadow:
    0 4px 18px rgba(9, 36, 59, 0.16);
}

.app-header h1 {
  margin: 0;

  font-size: clamp(38px, 5vw, 58px);

  line-height: 1;

  font-weight: 800;

  letter-spacing: -2px;
}

.app-header p {
  margin: 8px 0 0;

  font-size: 16px;

  font-weight: 700;

  letter-spacing: 1.5px;

  text-transform: uppercase;

  opacity: 0.9;
}

.app-header span {
  display: block;

  margin-top: 4px;

  font-size: 17px;

  font-weight: 600;

  color: #dce8f1;
}

.logout-btn {
  border: 1px solid rgba(255, 255, 255, 0.3);

  background: rgba(255, 255, 255, 0.1);

  color: white;

  border-radius: 12px;

  padding: 12px 20px;

  font-weight: 700;

  white-space: nowrap;

  transition:
    background 0.15s ease,
    transform 0.15s ease;
}

.logout-btn:hover {
  background: rgba(255, 255, 255, 0.18);

  transform: translateY(-1px);
}


/* ============================================
   MAIN CONTAINER
   ============================================ */

.app-container {
  width: min(1180px, calc(100% - 40px));

  margin: 32px auto 60px;
}


/* ============================================
   ADD STUDENT
   ============================================ */

.add-student-btn {
  width: 100%;

  border: none;

  background: var(--red);

  color: white;

  border-radius: 16px;

  padding: 17px 24px;

  margin-bottom: 18px;

  font-size: 19px;

  font-weight: 800;

  box-shadow:
    0 6px 16px rgba(201, 39, 50, 0.16);

  transition:
    transform 0.15s ease,
    background 0.15s ease,
    box-shadow 0.15s ease;
}

.add-student-btn:hover {
  background: var(--red-dark);

  transform: translateY(-1px);

  box-shadow:
    0 8px 20px rgba(201, 39, 50, 0.22);
}


/* ============================================
   SEARCH
   ============================================ */

.search-container {
  background: white;

  border-radius: var(--radius);

  padding: 24px;

  margin-bottom: 24px;

  box-shadow: var(--shadow);
}

#search-input {
  width: 100%;

  border: 2px solid var(--border);

  border-radius: 14px;

  background: white;

  color: var(--text);

  padding: 16px 18px;

  font-size: 18px;

  outline: none;

  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}

#search-input:focus {
  border-color: var(--navy);

  box-shadow:
    0 0 0 4px rgba(16, 47, 75, 0.08);
}

#search-input::placeholder {
  color: #8a9aaa;
}


/* ============================================
   STUDENT GRID
   ============================================ */

#student-list {
  display: grid;

  grid-template-columns:
    repeat(2, minmax(0, 1fr));

  gap: 20px;
}


/* ============================================
   STUDENT CARD
   ============================================ */

.student-card {
  background: white;

  border-radius: var(--radius);

  padding: 24px;

  box-shadow: var(--shadow);

  border: 1px solid rgba(216, 227, 235, 0.7);

  display: grid;

  grid-template-columns: 1fr auto;

  column-gap: 18px;

  row-gap: 20px;

  align-items: start;

  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

.student-card:hover {
  transform: translateY(-2px);

  box-shadow:
    0 12px 28px rgba(16, 47, 75, 0.11);
}

.student-info h2 {
  margin: 0;

  font-size: 23px;

  line-height: 1.15;

  font-weight: 800;

  color: var(--navy);

  letter-spacing: -0.4px;
}

.student-info p {
  margin: 6px 0 0;

  font-size: 15px;

  font-weight: 600;

  color: var(--muted);
}


/* ============================================
   BALANCE
   ============================================ */

.student-balance {
  min-width: 92px;

  padding: 10px 14px;

  border-radius: 15px;

  background: var(--green-light);

  color: var(--green);

  text-align: center;
}

.student-balance strong {
  display: block;

  font-size: 32px;

  line-height: 1;

  font-weight: 850;
}

.student-balance span {
  display: block;

  margin-top: 4px;

  font-size: 10px;

  line-height: 1;

  text-transform: uppercase;

  letter-spacing: 1.2px;

  font-weight: 800;
}

.student-balance.medium-balance {
  background: #fff4d9;

  color: #a96b00;
}

.student-balance.low-balance {
  background: #fde8e8;

  color: var(--red);
}


/* ============================================
   PUNCH BUTTONS
   ============================================ */

.punch-buttons {
  grid-column: 1 / -1;

  display: grid;

  grid-template-columns:
    repeat(4, minmax(0, 1fr));

  gap: 10px;
}

.punch-btn {
  border: none;

  background: var(--navy);

  color: white;

  border-radius: 12px;

  padding: 14px 8px;

  min-height: 50px;

  font-size: 17px;

  font-weight: 800;

  transition:
    background 0.15s ease,
    transform 0.1s ease;
}

.punch-btn:hover:not(:disabled) {
  background: var(--navy-dark);

  transform: translateY(-1px);
}

.punch-btn:active:not(:disabled) {
  transform: translateY(0);
}

.punch-btn:disabled {
  opacity: 0.35;

  cursor: not-allowed;
}


/* ============================================
   EMPTY STATE
   ============================================ */

.empty-state {
  grid-column: 1 / -1;

  background: white;

  border-radius: var(--radius);

  padding: 55px 20px;

  text-align: center;

  box-shadow: var(--shadow);

  color: var(--muted);
}

.empty-state div {
  font-size: 42px;

  margin-bottom: 10px;
}

.empty-state p {
  margin: 0;

  font-size: 18px;

  font-weight: 600;
}


/* ============================================
   MODALS
   ============================================ */

.modal {
  position: fixed;

  inset: 0;

  z-index: 1000;

  background:
    rgba(9, 36, 59, 0.55);

  backdrop-filter: blur(4px);

  display: flex;

  align-items: center;

  justify-content: center;

  padding: 20px;
}

.modal-card {
  position: relative;

  width: 100%;

  max-width: 480px;

  background: white;

  border-radius: 24px;

  padding: 32px;

  box-shadow:
    0 25px 70px rgba(0, 0, 0, 0.2);
}

.modal-card h2 {
  margin: 0;

  color: var(--navy);

  font-size: 28px;

  font-weight: 800;
}

.modal-subtitle {
  margin: 7px 0 25px;

  color: var(--muted);

  font-size: 15px;
}

.modal-card label {
  display: block;

  margin: 18px 0 7px;

  color: var(--navy);

  font-size: 14px;

  font-weight: 800;
}

.modal-card input,
.modal-card select {
  width: 100%;

  border: 2px solid var(--border);

  border-radius: 12px;

  background: white;

  color: var(--text);

  padding: 13px 14px;

  font-size: 16px;

  outline: none;
}

.modal-card input:focus,
.modal-card select:focus {
  border-color: var(--navy);

  box-shadow:
    0 0 0 4px rgba(16, 47, 75, 0.08);
}

.modal-card .primary-btn {
  width: 100%;

  margin-top: 25px;

  font-size: 17px;
}

.modal-close {
  position: absolute;

  top: 14px;

  right: 16px;

  width: 38px;

  height: 38px;

  border: none;

  border-radius: 50%;

  background: #f1f5f8;

  color: var(--navy);

  font-size: 25px;

  line-height: 1;

  cursor: pointer;
}

.modal-close:hover {
  background: #e5edf2;
}


/* ============================================
   CONFIRMATION
   ============================================ */

#confirmation-message {
  margin: 20px 0;

  color: var(--muted);

  font-size: 17px;

  line-height: 1.55;
}

.confirmation-buttons {
  display: grid;

  grid-template-columns: 1fr 1fr;

  gap: 12px;

  margin-top: 25px;
}

.secondary-btn {
  border: 2px solid var(--border);

  background: white;

  color: var(--navy);

  border-radius: 12px;

  padding: 13px 18px;

  font-weight: 700;

  cursor: pointer;
}

.secondary-btn:hover {
  background: #f5f8fa;
}


/* ============================================
   MOBILE
   ============================================ */

@media (max-width: 800px) {

  .app-header {
    padding: 24px 20px;

    align-items: flex-start;
  }

  .app-header h1 {
    font-size: 40px;
  }

  .app-header p {
    font-size: 13px;
  }

  .app-header span {
    font-size: 15px;
  }

  .logout-btn {
    padding: 10px 14px;

    font-size: 14px;
  }

  .app-container {
    width: calc(100% - 24px);

    margin-top: 20px;
  }

  #student-list {
    grid-template-columns: 1fr;
  }

}


@media (max-width: 520px) {

  #login-screen {
    padding: 16px;
  }

  .login-card {
    padding: 40px 24px;

    border-radius: 22px;
  }

  .login-card h1 {
    font-size: 46px;
  }

  .login-card p {
    font-size: 18px;
  }

  .app-header {
    padding: 20px 16px;

    flex-direction: column;
  }

  .app-header h1 {
    font-size: 36px;
  }

  .logout-btn {
    align-self: stretch;
  }

  .search-container {
    padding: 16px;
  }

  .student-card {
    padding: 18px;

    grid-template-columns: 1fr auto;
  }

  .student-info h2 {
    font-size: 20px;
  }

  .student-balance {
    min-width: 76px;

    padding: 9px 10px;
  }

  .student-balance strong {
    font-size: 27px;
  }

  .punch-buttons {
    gap: 7px;
  }

  .punch-btn {
    padding: 13px 5px;

    font-size: 16px;
  }

  .modal-card {
    padding: 26px 20px;
  }

}/* ============================================
   CLEVELAND PTA SNACK SHACK
   ============================================ */

:root {
  --navy: #102f4b;
  --navy-dark: #09243b;
  --red: #c92732;
  --red-dark: #a91e27;
  --green: #24945f;
  --green-light: #e7f6ee;
  --cream: #fffdf9;
  --background: #f2f7fa;
  --white: #ffffff;
  --text: #102f4b;
  --muted: #6c8091;
  --border: #d8e3eb;
  --shadow: 0 8px 24px rgba(16, 47, 75, 0.08);
  --radius: 20px;
}


/* ============================================
   RESET
   ============================================ */

* {
  box-sizing: border-box;
}

html {
  margin: 0;
  padding: 0;
}

body {
  margin: 0;
  padding: 0;
  font-family:
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    Helvetica,
    Arial,
    sans-serif;

  background:
    linear-gradient(
      135deg,
      #f5fafc 0%,
      #edf4f8 100%
    );

  color: var(--text);
  min-height: 100vh;
}


/* ============================================
   GENERAL
   ============================================ */

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.hidden {
  display: none !important;
}


/* ============================================
   LOGIN
   ============================================ */

#login-screen {
  min-height: 100vh;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 30px;
}

.login-card {
  width: 100%;
  max-width: 520px;

  background: var(--white);

  border-radius: 28px;

  padding: 55px 45px;

  text-align: center;

  box-shadow:
    0 20px 60px rgba(16, 47, 75, 0.12);
}

.login-icon {
  font-size: 58px;
  line-height: 1;
  margin-bottom: 15px;
}

.login-card h1 {
  margin: 0;

  font-size: clamp(42px, 7vw, 64px);

  font-weight: 800;

  letter-spacing: -2px;

  color: var(--navy);
}

.login-card p {
  margin: 10px 0;

  font-size: 21px;

  color: var(--navy);
}

.login-card .login-subtitle {
  margin-top: 25px;

  font-size: 25px;

  font-weight: 700;
}

.small-text {
  font-size: 15px !important;
  color: var(--muted) !important;
  margin-top: 18px !important;
}


/* ============================================
   BUTTONS
   ============================================ */

.primary-btn {
  border: none;

  background: var(--red);

  color: white;

  border-radius: 12px;

  padding: 14px 24px;

  font-weight: 700;

  transition:
    transform 0.15s ease,
    background 0.15s ease,
    box-shadow 0.15s ease;
}

.primary-btn:hover {
  background: var(--red-dark);

  transform: translateY(-1px);

  box-shadow:
    0 5px 14px rgba(201, 39, 50, 0.25);
}

.primary-btn:active {
  transform: translateY(0);
}

.login-card .primary-btn {
  margin-top: 20px;

  font-size: 18px;

  padding: 15px 32px;
}


/* ============================================
   APP HEADER
   ============================================ */

.app-header {
  background:
    linear-gradient(
      135deg,
      var(--navy-dark),
      var(--navy)
    );

  color: white;

  padding:
    30px
    max(30px, calc((100vw - 1180px) / 2));

  display: flex;

  align-items: center;

  justify-content: space-between;

  gap: 25px;

  box-shadow:
    0 4px 18px rgba(9, 36, 59, 0.16);
}

.app-header h1 {
  margin: 0;

  font-size: clamp(38px, 5vw, 58px);

  line-height: 1;

  font-weight: 800;

  letter-spacing: -2px;
}

.app-header p {
  margin: 8px 0 0;

  font-size: 16px;

  font-weight: 700;

  letter-spacing: 1.5px;

  text-transform: uppercase;

  opacity: 0.9;
}

.app-header span {
  display: block;

  margin-top: 4px;

  font-size: 17px;

  font-weight: 600;

  color: #dce8f1;
}

.logout-btn {
  border: 1px solid rgba(255, 255, 255, 0.3);

  background: rgba(255, 255, 255, 0.1);

  color: white;

  border-radius: 12px;

  padding: 12px 20px;

  font-weight: 700;

  white-space: nowrap;

  transition:
    background 0.15s ease,
    transform 0.15s ease;
}

.logout-btn:hover {
  background: rgba(255, 255, 255, 0.18);

  transform: translateY(-1px);
}


/* ============================================
   MAIN CONTAINER
   ============================================ */

.app-container {
  width: min(1180px, calc(100% - 40px));

  margin: 32px auto 60px;
}


/* ============================================
   ADD STUDENT
   ============================================ */

.add-student-btn {
  width: 100%;

  border: none;

  background: var(--red);

  color: white;

  border-radius: 16px;

  padding: 17px 24px;

  margin-bottom: 18px;

  font-size: 19px;

  font-weight: 800;

  box-shadow:
    0 6px 16px rgba(201, 39, 50, 0.16);

  transition:
    transform 0.15s ease,
    background 0.15s ease,
    box-shadow 0.15s ease;
}

.add-student-btn:hover {
  background: var(--red-dark);

  transform: translateY(-1px);

  box-shadow:
    0 8px 20px rgba(201, 39, 50, 0.22);
}


/* ============================================
   SEARCH
   ============================================ */

.search-container {
  background: white;

  border-radius: var(--radius);

  padding: 24px;

  margin-bottom: 24px;

  box-shadow: var(--shadow);
}

#search-input {
  width: 100%;

  border: 2px solid var(--border);

  border-radius: 14px;

  background: white;

  color: var(--text);

  padding: 16px 18px;

  font-size: 18px;

  outline: none;

  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}

#search-input:focus {
  border-color: var(--navy);

  box-shadow:
    0 0 0 4px rgba(16, 47, 75, 0.08);
}

#search-input::placeholder {
  color: #8a9aaa;
}


/* ============================================
   STUDENT GRID
   ============================================ */

#student-list {
  display: grid;

  grid-template-columns:
    repeat(2, minmax(0, 1fr));

  gap: 20px;
}


/* ============================================
   STUDENT CARD
   ============================================ */

.student-card {
  background: white;

  border-radius: var(--radius);

  padding: 24px;

  box-shadow: var(--shadow);

  border: 1px solid rgba(216, 227, 235, 0.7);

  display: grid;

  grid-template-columns: 1fr auto;

  column-gap: 18px;

  row-gap: 20px;

  align-items: start;

  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

.student-card:hover {
  transform: translateY(-2px);

  box-shadow:
    0 12px 28px rgba(16, 47, 75, 0.11);
}

.student-info h2 {
  margin: 0;

  font-size: 23px;

  line-height: 1.15;

  font-weight: 800;

  color: var(--navy);

  letter-spacing: -0.4px;
}

.student-info p {
  margin: 6px 0 0;

  font-size: 15px;

  font-weight: 600;

  color: var(--muted);
}


/* ============================================
   BALANCE
   ============================================ */

.student-balance {
  min-width: 92px;

  padding: 10px 14px;

  border-radius: 15px;

  background: var(--green-light);

  color: var(--green);

  text-align: center;
}

.student-balance strong {
  display: block;

  font-size: 32px;

  line-height: 1;

  font-weight: 850;
}

.student-balance span {
  display: block;

  margin-top: 4px;

  font-size: 10px;

  line-height: 1;

  text-transform: uppercase;

  letter-spacing: 1.2px;

  font-weight: 800;
}

.student-balance.medium-balance {
  background: #fff4d9;

  color: #a96b00;
}

.student-balance.low-balance {
  background: #fde8e8;

  color: var(--red);
}


/* ============================================
   PUNCH BUTTONS
   ============================================ */

.punch-buttons {
  grid-column: 1 / -1;

  display: grid;

  grid-template-columns:
    repeat(4, minmax(0, 1fr));

  gap: 10px;
}

.punch-btn {
  border: none;

  background: var(--navy);

  color: white;

  border-radius: 12px;

  padding: 14px 8px;

  min-height: 50px;

  font-size: 17px;

  font-weight: 800;

  transition:
    background 0.15s ease,
    transform 0.1s ease;
}

.punch-btn:hover:not(:disabled) {
  background: var(--navy-dark);

  transform: translateY(-1px);
}

.punch-btn:active:not(:disabled) {
  transform: translateY(0);
}

.punch-btn:disabled {
  opacity: 0.35;

  cursor: not-allowed;
}


/* ============================================
   EMPTY STATE
   ============================================ */

.empty-state {
  grid-column: 1 / -1;

  background: white;

  border-radius: var(--radius);

  padding: 55px 20px;

  text-align: center;

  box-shadow: var(--shadow);

  color: var(--muted);
}

.empty-state div {
  font-size: 42px;

  margin-bottom: 10px;
}

.empty-state p {
  margin: 0;

  font-size: 18px;

  font-weight: 600;
}


/* ============================================
   MODALS
   ============================================ */

.modal {
  position: fixed;

  inset: 0;

  z-index: 1000;

  background:
    rgba(9, 36, 59, 0.55);

  backdrop-filter: blur(4px);

  display: flex;

  align-items: center;

  justify-content: center;

  padding: 20px;
}

.modal-card {
  position: relative;

  width: 100%;

  max-width: 480px;

  background: white;

  border-radius: 24px;

  padding: 32px;

  box-shadow:
    0 25px 70px rgba(0, 0, 0, 0.2);
}

.modal-card h2 {
  margin: 0;

  color: var(--navy);

  font-size: 28px;

  font-weight: 800;
}

.modal-subtitle {
  margin: 7px 0 25px;

  color: var(--muted);

  font-size: 15px;
}

.modal-card label {
  display: block;

  margin: 18px 0 7px;

  color: var(--navy);

  font-size: 14px;

  font-weight: 800;
}

.modal-card input,
.modal-card select {
  width: 100%;

  border: 2px solid var(--border);

  border-radius: 12px;

  background: white;

  color: var(--text);

  padding: 13px 14px;

  font-size: 16px;

  outline: none;
}

.modal-card input:focus,
.modal-card select:focus {
  border-color: var(--navy);

  box-shadow:
    0 0 0 4px rgba(16, 47, 75, 0.08);
}

.modal-card .primary-btn {
  width: 100%;

  margin-top: 25px;

  font-size: 17px;
}

.modal-close {
  position: absolute;

  top: 14px;

  right: 16px;

  width: 38px;

  height: 38px;

  border: none;

  border-radius: 50%;

  background: #f1f5f8;

  color: var(--navy);

  font-size: 25px;

  line-height: 1;

  cursor: pointer;
}

.modal-close:hover {
  background: #e5edf2;
}


/* ============================================
   CONFIRMATION
   ============================================ */

#confirmation-message {
  margin: 20px 0;

  color: var(--muted);

  font-size: 17px;

  line-height: 1.55;
}

.confirmation-buttons {
  display: grid;

  grid-template-columns: 1fr 1fr;

  gap: 12px;

  margin-top: 25px;
}

.secondary-btn {
  border: 2px solid var(--border);

  background: white;

  color: var(--navy);

  border-radius: 12px;

  padding: 13px 18px;

  font-weight: 700;

  cursor: pointer;
}

.secondary-btn:hover {
  background: #f5f8fa;
}


/* ============================================
   MOBILE
   ============================================ */

@media (max-width: 800px) {

  .app-header {
    padding: 24px 20px;

    align-items: flex-start;
  }

  .app-header h1 {
    font-size: 40px;
  }

  .app-header p {
    font-size: 13px;
  }

  .app-header span {
    font-size: 15px;
  }

  .logout-btn {
    padding: 10px 14px;

    font-size: 14px;
  }

  .app-container {
    width: calc(100% - 24px);

    margin-top: 20px;
  }

  #student-list {
    grid-template-columns: 1fr;
  }

}


@media (max-width: 520px) {

  #login-screen {
    padding: 16px;
  }

  .login-card {
    padding: 40px 24px;

    border-radius: 22px;
  }

  .login-card h1 {
    font-size: 46px;
  }

  .login-card p {
    font-size: 18px;
  }

  .app-header {
    padding: 20px 16px;

    flex-direction: column;
  }

  .app-header h1 {
    font-size: 36px;
  }

  .logout-btn {
    align-self: stretch;
  }

  .search-container {
    padding: 16px;
  }

  .student-card {
    padding: 18px;

    grid-template-columns: 1fr auto;
  }

  .student-info h2 {
    font-size: 20px;
  }

  .student-balance {
    min-width: 76px;

    padding: 9px 10px;
  }

  .student-balance strong {
    font-size: 27px;
  }

  .punch-buttons {
    gap: 7px;
  }

  .punch-btn {
    padding: 13px 5px;

    font-size: 16px;
  }

  .modal-card {
    padding: 26px 20px;
  }

}
