* {
  box-sizing: border-box;
  font-family: Arial, sans-serif;
}

body {
  margin: 0;
  padding: 0;
  background: #f5f5f5;
  font-size: 16px;
}

h1 {
  text-align: center;
  margin-bottom: 20px;
  font-size: 2rem;
  font-weight: bold;
  color: #1f2937;
}

.container {
  max-width: 1000px;
  margin: 0 auto;
  background: #ffffff;
  padding: 24px;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  border-bottom: 2px solid #e0e0e0;
}

.tab-btn {
  padding: 12px 20px;
  border: none;
  border-radius: 4px 4px 0 0;
  background: #f5f5f5;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  color: #666;
  transition: all 0.2s;
}

.tab-btn.active {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  border-bottom: 3px solid #667eea;
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

.form-row {
  display: flex;
  gap: 15px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.form-group {
  flex: 1;
  min-width: 180px;
  display: flex;
  flex-direction: column;
}

label {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 6px;
  color: #333;
}

input, select, textarea {
  padding: 12px 14px;
  border-radius: 8px;
  border: 2px solid #e0e0e0;
  font-size: 15px;
  transition: all 0.2s;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: #667eea;
  background: #f8f9ff;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

textarea {
  resize: vertical;
  min-height: 80px;
  font-family: inherit;
}

.actions {
  display: flex;
  gap: 10px;
  margin: 10px 0 20px 0;
}

.actions button {
  padding: 6px 10px;
  border: none;
  border-radius: 4px;
  font-size: 13px;
  cursor: pointer;
  background: #e0e0e0;
}

.actions button.active {
  background: #3b82f6;
  color: #fff;
}

.scroll-box-wrapper {
  margin-top: 20px;
}

.scroll-box-title {
  font-weight: 600;
  font-size: 18px;
  margin-bottom: 12px;
  color: #333;
  padding-bottom: 8px;
  border-bottom: 2px solid #e0e0e0;
}

.scroll-box {
  border: none;
  border-radius: 8px;
  padding: 0;
  background: transparent;
}

/* Task List: show all items, no internal scroll */
#requestList {
  max-height: none;
  overflow-y: visible;
}

/* History list: show all items, no internal scroll */
#historyList {
  max-height: none;
  overflow-y: visible;
}

.request-item {
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  padding: 14px 16px;
  font-size: 14px;
  background: #ffffff;
  margin-bottom: 12px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  transition: all 0.2s;
}

.request-item:hover {
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  border-color: #667eea;
}

.request-item:last-child {
  margin-bottom: 0;
}

.request-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid #f0f0f0;
}

.request-type {
  font-weight: 700;
  font-size: 16px;
  color: #667eea;
}

.request-meta {
  font-size: 13px;
  color: #999;
}

.request-detail {
  font-size: 14px;
  line-height: 1.6;
  color: #555;
}

.item-actions {
  margin-top: 12px;
  display: flex;
  gap: 8px;
}

.item-actions button {
  flex: 1;
  padding: 8px 12px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 6px;
  border: 2px solid;
  background: white;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-edit {
  color: #667eea;
  border-color: #667eea;
}

.btn-edit:hover {
  background: #667eea;
  color: white;
}

.btn-delete {
  color: #e74c3c;
  border-color: #e74c3c;
}

.btn-delete:hover {
  background: #e74c3c;
  color: white;
}

.btn-submit {
  margin-top: 10px;
  padding: 14px 20px;
  border: none;
  border-radius: 8px;
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #fff;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
  transition: all 0.2s;
}

.btn-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(245, 158, 11, 0.4);
}

.btn-clear {
  margin-top: 10px;
  padding: 14px 20px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  background: white;
  color: #666;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  transition: all 0.2s;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.btn-clear:hover {
  background: #f5f5f5;
  border-color: #999;
  color: #333;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.tools-row {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* Mobile Responsive Styles */
@media (max-width: 768px) {
  body {
    padding: 0;
  }
  
  .container {
    border-radius: 0;
    padding: 12px;
    min-height: 100vh;
  }
  
  h1 {
    font-size: 1.5rem;
    margin-bottom: 12px;
  }
  
  .tabs {
    position: sticky;
    top: 0;
    background: white;
    z-index: 10;
    margin: -12px -12px 12px -12px;
    padding: 0 12px;
  }
  
  .tab-btn {
    flex: 1;
    padding: 14px 8px;
    font-size: 15px;
  }
  
  .form-row {
    flex-direction: column;
    gap: 12px;
    margin-bottom: 12px;
  }
  
  .form-group {
    min-width: 100%;
  }
  
  label {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 6px;
  }
  
  input, select, textarea {
    padding: 14px 12px;
    font-size: 16px;
    border: 2px solid #ddd;
    border-radius: 8px;
  }
  
  input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #1976d2;
    background: #f8f9ff;
  }
  
  textarea {
    min-height: 80px;
  }
  
  .actions {
    flex-direction: column;
    gap: 8px;
  }
  
  .actions button {
    width: 100%;
    padding: 12px;
    font-size: 15px;
  }
  
  .btn-submit {
    width: 100%;
    padding: 16px;
    font-size: 18px;
    font-weight: 600;
  }
  
  .scroll-box-title {
    font-size: 16px;
    margin-bottom: 10px;
  }
  
  .request-item {
    padding: 12px;
    font-size: 14px;
    border: 2px solid #ddd;
    border-radius: 8px;
    margin-bottom: 12px;
  }
  
  .request-type {
    font-size: 16px;
  }
  
  .request-meta {
    font-size: 13px;
  }
  
  .request-detail {
    font-size: 14px;
    line-height: 1.6;
  }
  
  .item-actions {
    margin-top: 10px;
    gap: 8px;
  }
  
  .item-actions button {
    flex: 1;
    padding: 10px 8px;
    font-size: 14px;
    font-weight: 600;
    border: 2px solid #ddd;
    border-radius: 6px;
  }
  
  .tools-row {
    flex-direction: column;
    gap: 8px;
  }
  
  .tools-row button {
    width: 100%;
    padding: 14px;
    font-size: 15px;
  }
}
