@import url("https://fonts.googleapis.com/css2?family=Manrope:wght@400;700&display=swap");
/* Base */
:root {
  --primary: #1a3a32; /* can be adjusted to match your brand */
  --text: #1a1a1a;
  --muted: #6b7280;
  --surface: #ffffff;
  --border: #e5e7eb;
  --overlay: rgba(0, 0, 0, 0.5);
  --radius: 16px;
}
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  padding: 0;
}
body {
  font-family: Manrope, system-ui, -apple-system, Segoe UI, Roboto, Helvetica,
    Arial, sans-serif;
  color: var(--text);
}

/* Button iframe page layout */
.page-root {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Fallback iframe inside modal */
.calc-frame {
  width: 100%;
  height: 80vh;
  border: 0;
  border-radius: 12px;
}
.open-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  color: #e53935;
  background: transparent;
  border: 2px solid #e53935;
  padding: 12px 20px;
  border-radius: 8px;
  font-weight: 600;
  transition: 0.3s;
}
.open-btn:hover {
  background: #e53935;
  color: #fff;
}

/* Modal overlay inside the iframe (fixed within iframe bounds) */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--overlay);
  align-items: center;
  justify-content: center;
  z-index: 1000;
}
.modal[aria-hidden="false"] {
  display: flex;
}
.modal-content {
  background: var(--surface);
  width: 100%;
  max-width: 960px;
  max-height: 90vh;
  overflow: auto;
  border-radius: var(--radius);
  padding: 2rem;
  position: relative;
}
/* Padding pro kalkulačku v parent iframe modalu */
body > .calc-wrap {
  padding: 2rem;
}
/* Skrýt vnitřní zavírací tlačítko kalkulačky, když je v parent modalu */
body:not(.calc-embedded) .calc-header .close-btn {
  display: none;
}

.close-btn {
  border: none;
  background: transparent;
  font-size: 28px;
  cursor: pointer;
}

/* Calculator UI (calc.html content) */
.calc-wrap {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.calc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.calc-title {
  font-size: 32px;
  font-weight: 700;
  margin: 0;
}
.subtitle-accent {
  color: #16a34a;
  font-weight: 600;
  font-size: 0.75em;
  background: #f0fdf4;
  padding: 6px 14px;
  border-radius: 20px;
  display: inline-block;
  margin-left: 8px;
  vertical-align: middle;
}
.calc-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@media (min-width: 768px) {
  .calc-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
.field label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 16px;
  background: #fff;
}
.btn-primary {
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 9999px;
  padding: 12px 20px;
  font-weight: 700;
  cursor: pointer;
}
.btn-primary:hover {
  filter: brightness(0.95);
}
.cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@media (min-width: 768px) {
  .cards {
    grid-template-columns: 1fr 1fr;
  }
}
.card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 18px;
}
.card .label {
  font-size: 14px;
  font-weight: 600;
  margin: 0 0 4px;
}
.card .value {
  font-size: 28px;
  font-weight: 800;
  margin: 0 0 4px;
}
.card .muted {
  color: var(--muted);
  font-size: 13px;
  margin: 0;
}
/* Global muted text */
.muted {
  color: var(--muted);
}
.hr {
  height: 1px;
  background: var(--border);
  border: 0;
  margin: 8px 0;
}
.row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}

/* Simple utilities */
.mt-8 {
  margin-top: 8px;
}
.text-xs {
  font-size: 12px;
}
.calc-subtitle {
  font-size: 24px;
  font-weight: 700;
}
.contact-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.btn-secondary {
  background: #fff;
  color: var(--primary);
  border: 2px solid var(--primary);
  border-radius: 9999px;
  padding: 12px 20px;
  font-weight: 700;
  cursor: pointer;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@media (min-width: 768px) {
  .form-grid {
    grid-template-columns: 1fr 1fr;
  }
  .form-grid.three-cols {
    grid-template-columns: 1fr 1fr 1fr;
  }
}
