/* ==========================================================================
   Boycotts Card Styles (used another content class to build it)
   themes/danland/css/boycotts.css
   ========================================================================== */

/* === Base Card === */
.organization-card {
  border: 1px solid #ccc;
  border-radius: 6px;
  overflow: hidden;
  background: #fff;
  text-align: left; /* override any parent centering */
  padding: 0;       /* children handle spacing */
  max-width: 960px;
  margin: 0 auto;
}

/* === Header === */
.organization__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #eef3ff;
  padding: .3rem 1rem 0 1rem;
  border-bottom: 1px solid #ccc;
  margin: 0;
}

.organization__author {
  display: flex;
  align-items: center;
  gap: .75rem;
}

.organization__avatar img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.organization__name {
  font-weight: 600;
  color: #2d3a66;
  white-space: nowrap;
}

.organization__meta {
  margin-left: auto;
  white-space: nowrap;
  color: #334155;
  font-size: .9rem;
  opacity: .75;
  display: inline-flex;
  gap: .5rem;
}

/* === Title === */
.organization__title {
  margin: 1rem;
  line-height: 1.2;
  white-space: normal;      /* allow wrapping at spaces */
  overflow-wrap: anywhere; /* long URLs will break if needed */
  word-break: keep-all;     /* keep words intact */
  hyphens: none;            /* don’t hyphenate */
}

.organization__title a {
  text-decoration: none;
}

/* === Images === */
.organization__image,
.org__image {
  display: flex;
  justify-content: center;
  margin: 1rem auto 1.25rem;
  max-width: 900px;
  border-radius: 6px;
  overflow: hidden;
}

.organization__image img,
.org__image img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: inherit;
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
}

/* === Body & Sections === */
.org__body {
  display: inline-block;
  text-align: left;
  max-width: 780px;
  width: 100%;
  padding: 1rem;
  margin: 0 auto;
}

.org__sections {
  display: grid;
  gap: 1rem;
  max-width: 100%;
}

.org__section-title {
  margin: 0 0 .4rem 0;
  font-weight: 700;
  text-align: left;
  color: #222;
}

.org__section-box {
  border: 1px solid #ccc;
  border-radius: 6px;
  background: #fff;
  padding: .75rem 1rem;
  width: 100%;
  box-sizing: border-box;
}

/* === Row Layouts === */
.org__row {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: .5rem .75rem;
  align-items: start;
  justify-items: start;
  margin: .4rem 0;
}

.org__label {
  font-weight: 600;
  text-align: right;
}

.org__value {
  text-align: left;
}

/* === Footer === */
.org__footer {
  margin-top: .75rem;
  padding: .5rem 1rem 1rem;
  display: flex;  /* Change from inline-flex to flex */
  gap: .5rem;
  align-items: center;
  width: 100%;  /* Ensure full width */
}

/* === Buttons === */
.btn-op {
  display: inline-block;
  padding: .35rem .7rem;
  border-radius: 8px;
  text-decoration: none;
  border: 1px solid #d8d8d8;
  font-size: .95rem;
}

.btn-op--edit {
  background: #f7faff;
  border-color: #cfe2ff;
}

.btn-op--delete {
  background: #fff5f5;
  border-color: #f3c0c0;
}

/* Make sure all organization card children respect the container */
.organization-card,
.organization-card * {
  box-sizing: border-box;
  max-width: 100%;
}

/* Optional: tighten inner sections so they never spill */
.org__body,
.org__sections,
.org__section,
.org__section-box,
.org__footer {
  max-width: 100%;
  overflow-wrap: break-word; /* prevent long text from pushing out */
}

.organization-card {
  border: 1px solid #ccc;
  border-radius: 6px;
  overflow: hidden;
  background: #fff;
  padding: 0; /* keep inner spacing handled by children */
  text-align: left;
  margin-bottom: 2rem; /* ✅ adds breathing room below each card */
}

.org__created {
  margin-left: auto;
  text-align: right;
}

.organization__avatar-link,
.organization__name-link {
  text-decoration: none;
  color: inherit;
}

.organization__avatar-link:hover .organization__avatar {
  opacity: 0.8;
  transition: opacity 0.2s ease;
}

form.node-boycott-form {
  border: 1px solid #ccc;
  border-radius: 8px;
  background-color: #f0f4ff;
  padding: 1.5rem;
  margin: .2rem 0 4rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

form.node-boycott-form .form-item {
  margin-bottom: 1.25rem;
}

form.node-boycott-form label {
  font-weight: 600;
  font-size: 1rem;
  color: #2a3f8d;
  margin-bottom: 0.25rem;
  display: inline-block;
}

/* etc. (just replace .boycott-form-wrapper with form.node-boycott-form in your CSS) */

/* Target the boycott edit form specifically */
form#node-boycott-edit-form {
  background-color: #f0f4ff !important;
  border: 1px solid #ccc !important;
  border-radius: 6px !important;
  padding: 20px !important;
  margin: 2px auto !important;
  max-width: 900px !important;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

/* Keep spacing tidy */
form#node-boycott-edit-form .form-item {
  margin-bottom: 1.2em !important;
}

/* Buttons */
form#node-boycott-edit-form input.button {
  border-radius: 6px !important;
  padding: 8px 20px !important;
  font-weight: 600;
}

/* Primary button style */
form#node-boycott-edit-form .button--primary {
  background-color: #4759d1 !important;
  color: #fff !important;
  border: none !important;
}

/* Delete button */
form#node-boycott-edit-form .button--danger {
  background-color: #723882 !important;
  border-radius: 6px !important;
  color: #fff !important;
  border: none !important;
  padding: 8px 20px !important;
}

form#node-boycott-edit-form .form-item-revision {
  display: none !important;
}
