
* {
  box-sizing: border-box;
}

:root {
  --primary: #D90000;
  --background: #f5f6f3;
  --surface: #ffffff;
  --border: #dce2dc;
  --text: #202720;
  --muted: #68736b;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: var(--background);
  color: var(--text);
  line-height: 1.5;
}

header {
  background: var(--primary);
  color: white;
  padding: 24px 6%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

header h1 {
  margin: 0;
  font-size: 1.6rem;
}

header a {
  color: white;
  text-decoration: none;
}

header a:hover {
  text-decoration: underline;
}

main {
  max-width: 1100px;
  margin: 32px auto;
  padding: 0 20px;
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
  align-items: start;
}

section {
  min-width: 0;
}

.calendar-section,
.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 22px;
}

.section-heading,
.calendar-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

h2, h3 {
  margin-top: 0;
}

.calendar-controls h3 {
  margin: 0;
  text-align: center;
}

button {
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 6px;
  padding: 10px 14px;
  cursor: pointer;
  font: inherit;
}

button:hover {
  opacity: 0.88;
}

button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid #528b73;
  outline-offset: 2px;
}

.calendar {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  border-top: 1px solid var(--border);
  border-left: 1px solid var(--border);
  margin: 20px 0 28px;
}

.day {
  min-height: 78px;
  padding: 7px;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: white;
  overflow-wrap: anywhere;
}

.day-name {
  min-height: auto;
  background: #edf1ed;
  font-size: 0.8rem;
  font-weight: bold;
  text-align: center;
}

.day.today {
  background: #e8f2eb;
}

.day-number {
  font-weight: bold;
}

.day-event {
  display: block;
  margin-top: 4px;
  padding: 3px;
  background: #dcebe1;
  color: #24483d;
  border-radius: 4px;
  font-size: 0.72rem;
}

form {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

label {
  font-size: 0.9rem;
  font-weight: bold;
}

input, textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font: inherit;
  margin-bottom: 8px;
}

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

.event-card,
.contact-card {
  border-bottom: 1px solid var(--border);
  padding: 14px 0;
  overflow-wrap: anywhere;
}

.event-card:last-child,
.contact-card:last-child {
  border-bottom: none;
}

.event-card h4,
.contact-card h4 {
  margin: 0 0 4px;
}

.event-card p,
.contact-card p {
  margin: 4px 0;
  color: var(--muted);
}

.card-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.card-actions button {
  font-size: 0.85rem;
}

button.delete {
  background: #8d3434;
}

.empty {
  color: var(--muted);
}

footer {
  text-align: center;
  color: var(--muted);
  padding: 20px;
}

@media (max-width: 750px) {
  main {
    grid-template-columns: 1fr;
    margin-top: 18px;
    padding: 0 12px;
  }

  header {
    padding: 20px 16px;
    flex-wrap: wrap;
  }

  .calendar-section,
  .panel {
    padding: 14px;
  }

  .day {
    min-height: 58px;
    padding: 4px;
    font-size: 0.85rem;
  }

  .day-event {
    font-size: 0.65rem;
  }
}




header {
  min-height: 250px;
  padding: 32px 6%;
  align-items: center;
}

.brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}

.org-logo {
  width: 220px;
  height: 110px;
  object-fit: contain;
  object-position: left center;
}

.brand h1 {
  margin: 0;
  font-size: 1.5rem;
}

@media (max-width: 600px) {
  header {
    padding: 24px 5%;
    gap: 20px;
    flex-wrap: wrap;
  }

  .org-logo {
    width: 160px;
    height: 80px;
  }

  .brand h1 {
    font-size: 1.2rem;
  }
}


[hidden] {
  display: none !important;
}
