:root {
  --primary: #1a73e8;
  --success: #34a853;
  --danger: #ea4335;
  --dark: #202124;
  --light: #f8f9fa;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: var(--dark);
  background: var(--light);
  padding: 15px;
}

.form-container {
  max-width: 400px;
  margin: 50px auto;
  text-align: center;
}

input, button {
  width: 100%;
  padding: 14px;
  margin: 10px 0;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 16px;
}

button {
  background: var(--primary);
  color: white;
  border: none;
  cursor: pointer;
  font-weight: bold;
  transition: background 0.3s;
}

button:hover {
  background: #0d5bb5;
}

.error {
  color: var(--danger);
  min-height: 20px;
  margin-top: 5px;
}

#main-app {
  display: none;
}

header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.controls {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 20px;
}

.hidden {
  display: none;
}

#reader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: black;
  z-index: 100;
}

#form-section {
  background: white;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  margin-bottom: 20px;
}

input[type="number"] {
  text-align: center;
}

textarea {
  min-height: 80px;
  resize: vertical;
}

.recent-section {
  background: white;
  padding: 15px;
  border-radius: 8px;
  margin-bottom: 20px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

#recent-list {
  list-style: none;
}

#recent-list li {
  padding: 8px 0;
  border-bottom: 1px solid #eee;
}

.search-container {
  margin-bottom: 15px;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

th, td {
  padding: 12px 15px;
  text-align: left;
  border-bottom: 1px solid #eee;
}

th {
  background: #f1f3f4;
  font-weight: bold;
}

.actions {
  display: flex;
  gap: 5px;
}

.actions button {
  padding: 5px 10px;
  font-size: 14px;
  width: auto;
}

.edit-btn {
  background: #fbbc05;
}

.delete-btn {
  background: var(--danger);
}

@media (max-width: 768px) {
  .controls {
    grid-template-columns: 1fr;
  }
  
  th:nth-child(3),
  td:nth-child(3),
  th:nth-child(5),
  td:nth-child(5) {
    display: none;
  }
}