*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg: #1a1a1a;
  --panel: #202020;
  --line: #555;
  --text: #ffffff;
  --dim: #aaaaaa;
  --green: greenyellow;
  --yellow: #ffd85c;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-height: 100vh;
  padding: 10px;
  background: var(--bg);
  color: var(--text);
  font-family: Georgia, "Times New Roman", serif;
}

a,
button,
input,
select {
  font: inherit;
}

.app-shell {
  width: 100%;
  max-width: 980px;
  margin: 0 auto;
}

/* Header */

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
  padding: 16px 0 12px;
  margin-bottom: 8px;
  border-bottom: 1px solid #444;
}

.site-header h1 {
  font-size: 1.8rem;
  font-weight: 400;
  letter-spacing: 0.02em;
}

.site-header p {
  margin-top: 3px;
  color: var(--dim);
}

.data-state {
  flex-shrink: 0;
  padding: 6px 8px;
  color: #dddddd;
  border: 1px solid var(--line);
  font-family: Arial, sans-serif;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  white-space: nowrap;
}

/* Main menu */

.menu-container {
  display: block;
  width: 100%;
  margin: 30px 0;
}

.calculator-list {
  display: grid;
  width: 100%;
  gap: 8px;
}

.calculator-option {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 90px;
  gap: 20px;
  align-items: center;
  width: 100%;
  min-height: 150px;
  padding: 18px;
  color: var(--text);
  background: var(--panel);
  border: 1px solid var(--line);
  text-decoration: none;
  transition:
    background-color 0.2s,
    border-color 0.2s;
}

.calculator-option:hover {
  background: #292929;
  border-color: var(--green);
}

.calculator-info {
  min-width: 0;
}

.calculator-info h2 {
  margin: 8px 0;
  font-size: 1.35rem;
  font-weight: 400;
}

.calculator-info p {
  color: var(--dim);
  font-family: Arial, sans-serif;
  font-size: 0.8rem;
  line-height: 1.5;
}

/* Status labels */

.calculator-status {
  display: inline-block;
  padding: 4px 6px;
  border: 1px solid;
  font-family: Arial, sans-serif;
  font-size: 0.62rem;
  letter-spacing: 0.1em;
}

.calculator-status.beta {
  color: var(--yellow);
  border-color: var(--yellow);
}

.calculator-status.available {
  color: var(--green);
  border-color: var(--green);
}

/* Open button */

.calculator-open {
  width: 90px;
  padding: 8px 10px;
  color: var(--text);
  background: #292929;
  border: 1px solid #777777;
  text-align: center;
  font-family: Arial, sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  transition:
    color 0.2s,
    background-color 0.2s,
    border-color 0.2s;
}

.calculator-option:hover .calculator-open {
  color: #111111;
  background: var(--green);
  border-color: var(--green);
}

/* Footer */

footer {
  border-top: 1px solid #444;
  margin-top: 20px;
  padding: 15px 0;
  color: #999;
  font-family: Arial, sans-serif;
  font-size: 0.95rem;
  line-height: 2.0;
  text-align: center;
  .footer-link {
    color: #b7ff7c;
    text-decoration: none;
  }
}

/* Tablet */

@media (max-width: 760px) {
  .app-shell {
    max-width: 100%;
  }
}

/* Mobile */

@media (max-width: 560px) {
  body {
    padding: 8px;
  }

  .site-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .site-header h1 {
    font-size: 1.5rem;
  }

  .menu-container {
    margin: 20px 0;
  }

  .calculator-option {
    grid-template-columns: 1fr;
    gap: 16px;
    min-height: 0;
    padding: 16px;
  }

  .calculator-open {
    width: 100%;
  }
}