* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  font-family: -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: #1a1a1a;
  background: #fafafa;
}
header {
  background: #111;
  color: #fff;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
header .brand {
  font-weight: 700;
  font-size: 1.25rem;
  text-decoration: none;
  color: #fff;
}
nav a {
  color: #fff;
  margin-left: 20px;
  text-decoration: none;
  font-size: 0.95rem;
}
nav a:hover { text-decoration: underline; }
main {
  max-width: 900px;
  margin: 0 auto;
  padding: 32px 24px;
}
.hero {
  text-align: center;
  padding: 48px 0;
}
.hero h1 { font-size: 2rem; margin-bottom: 8px; }
.hero p { color: #555; }
.search-bar {
  display: flex;
  gap: 8px;
  margin: 24px 0;
}
.search-bar input {
  flex: 1;
  padding: 10px 12px;
  font-size: 1rem;
  border: 1px solid #ccc;
  border-radius: 6px;
}
.search-bar button {
  padding: 10px 18px;
  font-size: 1rem;
  border: none;
  border-radius: 6px;
  background: #111;
  color: #fff;
  cursor: pointer;
}
.job-card {
  display: block;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 16px 20px;
  margin-bottom: 12px;
  text-decoration: none;
  color: inherit;
  background: #fff;
}
.job-card:hover { border-color: #999; }
.job-card h3 { margin: 0 0 4px; }
.job-card .meta { color: #666; font-size: 0.9rem; }
.job-detail h1 { margin-bottom: 4px; }
.job-detail .meta { color: #666; margin-bottom: 20px; }
.empty { color: #777; padding: 24px 0; }
.back-link { display: inline-block; margin-bottom: 16px; }
.category-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin: 32px 0;
}
.category-list .job-card { margin-bottom: 0; text-align: center; }
#category-label { color: #666; margin-bottom: 16px; }
#category-label a { color: #111; }

.admin-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.button-link {
  display: inline-block;
  padding: 10px 18px;
  border-radius: 6px;
  background: #111;
  color: #fff;
  text-decoration: none;
  font-size: 0.95rem;
}
.admin-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
}
.admin-table th, .admin-table td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid #e0e0e0;
  font-size: 0.95rem;
}
.admin-table th { color: #666; font-weight: 600; }
.admin-table tr:last-child td { border-bottom: none; }
.admin-actions { display: flex; gap: 12px; align-items: center; }
.link-button {
  background: none;
  border: none;
  padding: 0;
  font-size: 0.95rem;
  cursor: pointer;
  color: #111;
  text-decoration: underline;
}
.link-button.danger { color: #b3261e; }

.admin-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 520px;
}
.admin-form .form-row {
  display: flex;
  gap: 16px;
}
.admin-form .form-row label {
  flex: 1;
  min-width: 0;
}
.admin-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.9rem;
  color: #333;
}
.admin-form input, .admin-form textarea, .admin-form select {
  padding: 10px 12px;
  font-size: 1rem;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-family: inherit;
  width: 100%;
  box-sizing: border-box;
}
.admin-form select.placeholder-active {
  color: #9a9a9a;
}
.admin-form select option {
  color: #111;
}
.admin-form .checkbox-label {
  flex-direction: row;
  align-items: center;
  gap: 8px;
}
.admin-form .checkbox-label input { width: auto; }
.admin-form button {
  align-self: flex-start;
  padding: 10px 20px;
  font-size: 1rem;
  border: none;
  border-radius: 6px;
  background: #111;
  color: #fff;
  cursor: pointer;
}
.form-error {
  color: #b3261e;
  font-size: 0.9rem;
}

/* Home page */
.home-body { margin: 0; }
.top-contact-bar {
  height: 56px;
  background: #7cb0ec;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  padding: 0 120px 0 32px;
}
.contact-link {
  display: inline-block;
  background: #fff;
  font-size: 1.25rem;
  font-weight: 700;
  color: #0b2e57;
  text-decoration: none;
  letter-spacing: 0.02em;
  padding: 10px 28px;
  border-radius: 999px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}
.contact-link:hover {
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.22);
}
.home-topbar {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 24px;
  height: 130px;
  padding: 0 0 0 32px;
  background: #fff;
}
.site-name {
  align-self: center;
  font-weight: 700;
  font-size: 1.5rem;
  color: #111;
  text-decoration: none;
}
.home-image-space {
  flex: 0 1 80%;
  width: 80%;
  border-radius: 8px 0 0 8px;
  overflow: hidden;
  position: relative;
}
.banner-photo {
  display: block;
  width: 100%;
  height: auto;
  transform: translateY(-34%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 25%);
  mask-image: linear-gradient(to right, transparent 0%, #000 25%);
}
.accent-line {
  height: 6px;
  background: #7cb0ec;
  width: 100%;
}
.home-tagline {
  margin: 24px 32px 0;
  color: #1f7a3d;
  font-size: 2rem;
  text-transform: uppercase;
}
.home-main {
  max-width: none;
  margin: 0;
  padding: 0 4px 40px 32px;
  display: flex;
  align-items: center;
  min-height: 85vh;
}
.home-layout {
  display: flex;
  align-items: flex-start;
  gap: 40px;
  width: 100%;
}
.search-sidebar {
  flex: 0 0 25%;
  position: sticky;
  top: 24px;
}
.home-results {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 24px;
}
.home-job-card {
  display: block;
  width: 100%;
  background: #fff;
  border: 2px solid #0b2e57;
  border-radius: 16px;
  padding: 22px 26px;
  text-decoration: none;
}
.home-job-card:hover {
  background: #f5f9ff;
}
.home-job-title {
  margin: 0;
  text-align: left;
  font-weight: 700;
}
.home-job-profession {
  font-size: 1.3rem;
  color: #111;
}
.home-job-location {
  font-size: 0.85rem;
  color: #111;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.search-box {
  display: flex;
  flex-direction: column;
  width: 400px;
  gap: 40px;
  padding: 45px;
  background: #fff;
  border: 2px solid #111;
  border-radius: 20px;
}
.search-field {
  width: 100%;
  padding: 18px 20px;
  font-size: 1.5rem;
  font-family: Georgia, 'Times New Roman', serif;
  border: 1px solid #ccc;
  border-radius: 10px;
  background: #fff;
  color: #111;
  box-sizing: border-box;
}
select.search-field {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  cursor: pointer;
  padding-right: 48px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23111111' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 18px center;
  background-size: 18px;
}
.search-field option {
  color: #111;
}
select.search-field.placeholder-active {
  color: #9a9a9a;
}
.search-field::placeholder {
  color: #9a9a9a;
}
.search-submit {
  width: 100%;
  padding: 18px 35px;
  font-size: 1.5rem;
  font-weight: 600;
  font-family: Georgia, 'Times New Roman', serif;
  border: none;
  border-radius: 10px;
  background: #1b4f91;
  color: #fff;
  cursor: pointer;
  box-sizing: border-box;
}
.search-submit:hover {
  background: #163f74;
}
@media (max-width: 640px) {
  .home-topbar { flex-direction: column; align-items: flex-start; }
  .home-image-space { width: 100%; max-width: none; }
  .home-layout { flex-direction: column; }
  .search-sidebar { position: static; transform: none; flex-basis: auto; width: 100%; }
  .search-box { width: 100%; max-width: 400px; padding: 32px; }
}
