/* ====================================================
   Water Intake Calculator — WordPress Plugin Styles
   v1.1 — Teal palette · Cormorant + DM Sans · Dropdown activity
   ==================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cormorant:ital,wght@0,600;0,700;1,600;1,700&family=DM+Sans:wght@400;500;600;700&display=swap');

/* ── Wrapper & Custom Properties ───────────────────── */
#wic-app.wic-wrapper {
  --wic-bg:         #f0fdfa;
  --wic-card:       #ffffff;
  --wic-primary:    #0d9488;
  --wic-primary-dk: #0f766e;
  --wic-primary-lt: #ccfbf1;
  --wic-accent:     #14b8a6;
  --wic-accent2:    #5eead4;
  --wic-text:       #0f172a;
  --wic-muted:      #64748b;
  --wic-border:     #99f6e4;
  --wic-shadow:     0 20px 60px rgba(13,148,136,0.13), 0 4px 20px rgba(0,0,0,0.06);
  --wic-font:       'DM Sans', sans-serif;
  --wic-font-head:  'Cormorant', serif;

  font-family: var(--wic-font);
  display: flex;
  justify-content: center;
  padding: 32px 16px;
  background: var(--wic-bg);
  background-image:
    radial-gradient(circle at 15% 20%, rgba(13,148,136,0.09) 0%, transparent 50%),
    radial-gradient(circle at 85% 80%, rgba(20,184,166,0.09) 0%, transparent 50%);
  box-sizing: border-box;
}

/* ── Card ───────────────────────────────────────────── */
#wic-app.wic-wrapper .wic-card {
  background: var(--wic-card);
  border-radius: 24px;
  box-shadow: var(--wic-shadow);
  width: 100%;
  max-width: 620px;
  overflow: hidden;
  border: 1px solid rgba(13,148,136,0.12);
}

/* ── Header ─────────────────────────────────────────── */
#wic-app.wic-wrapper .wic-header {
  background: linear-gradient(135deg, #0d9488 0%, #0f766e 55%, #115e59 100%);
  padding: 36px 32px 28px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

#wic-app.wic-wrapper .wic-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 0%,  rgba(255,255,255,0.13) 0%, transparent 55%),
    radial-gradient(ellipse at 70% 100%, rgba(0,0,0,0.08) 0%, transparent 55%);
  pointer-events: none;
}

#wic-app.wic-wrapper .wic-drop-icon {
  width: 52px;
  height: 64px;
  margin: 0 auto 14px;
  position: relative;
  z-index: 1;
  filter: drop-shadow(0 4px 14px rgba(0,0,0,0.22));
  animation: wic-float 3s ease-in-out infinite;
}

@keyframes wic-float {
  0%, 100% { transform: translateY(0);   }
  50%       { transform: translateY(-6px); }
}

#wic-app.wic-wrapper .wic-title {
  font-family: 'Cormorant', serif !important;
  font-size: 2.1rem !important;
  font-weight: 700 !important;
  font-style: italic !important;
  color: #fff !important;
  margin: 0 0 6px !important;
  padding: 0 !important;
  position: relative;
  z-index: 1;
  letter-spacing: 0.01em;
  line-height: 1.1;
  text-shadow: 0 2px 8px rgba(0,0,0,0.15);
  border: none !important;
  background: none !important;
}

#wic-app.wic-wrapper .wic-subtitle {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.88rem;
  color: rgba(255,255,255,0.82);
  margin: 0;
  position: relative;
  z-index: 1;
  font-weight: 400;
}

/* ── Labels (field headings) ────────────────────────── */
#wic-app.wic-wrapper .wic-label {
  font-family: 'Cormorant', serif !important;
  font-size: 1rem !important;
  font-weight: 700 !important;
  font-style: normal !important;
  color: var(--wic-primary-dk) !important;
  text-transform: none !important;
  letter-spacing: 0.01em;
  line-height: 1;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  background: none !important;
}

/* ── Form ───────────────────────────────────────────── */
#wic-app.wic-wrapper .wic-form {
  padding: 28px 32px 32px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

/* ── Unit Toggle ────────────────────────────────────── */
#wic-app.wic-wrapper .wic-unit-toggle {
  display: flex;
  background: var(--wic-primary-lt);
  border-radius: 10px;
  padding: 4px;
  gap: 4px;
}

/* ── WP Global Button Reset (scoped tightly) ─────────── */
#wic-app.wic-wrapper button {
  -webkit-appearance: none !important;
  appearance: none !important;
  font-family: 'DM Sans', sans-serif !important;
  line-height: normal !important;
  text-decoration: none !important;
  letter-spacing: normal !important;
}

#wic-app.wic-wrapper .wic-unit-btn {
  flex: 1 !important;
  padding: 8px 12px !important;
  border: none !important;
  border-radius: 7px !important;
  background: transparent !important;
  font-family: 'DM Sans', sans-serif !important;
  font-size: 0.82rem !important;
  font-weight: 600 !important;
  color: var(--wic-muted) !important;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: none !important;
  outline: none !important;
  text-shadow: none !important;
}

#wic-app.wic-wrapper .wic-unit-btn.active {
  background: var(--wic-primary) !important;
  color: #fff !important;
  box-shadow: 0 2px 8px rgba(13,148,136,0.35) !important;
}

#wic-app.wic-wrapper .wic-unit-btn:hover:not(.active) {
  background: rgba(13,148,136,0.1) !important;
  color: var(--wic-primary) !important;
}

/* ── Row ────────────────────────────────────────────── */
#wic-app.wic-wrapper .wic-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

/* ── Field ──────────────────────────────────────────── */
#wic-app.wic-wrapper .wic-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#wic-app.wic-wrapper .wic-field--full { width: 100%; }

/* ── Pill Groups ────────────────────────────────────── */
#wic-app.wic-wrapper .wic-pill-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

#wic-app.wic-wrapper .wic-pill {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 5px;
  padding: 7px 16px !important;
  border-radius: 50px !important;
  border: 1.5px solid var(--wic-border) !important;
  background: transparent !important;
  font-family: 'DM Sans', sans-serif !important;
  font-size: 0.84rem !important;
  font-weight: 600 !important;
  color: var(--wic-muted) !important;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
  box-shadow: none !important;
  text-shadow: none !important;
  line-height: 1.3 !important;
  outline: none !important;
}

#wic-app.wic-wrapper .wic-pill:hover {
  border-color: var(--wic-primary) !important;
  color: var(--wic-primary) !important;
  background: var(--wic-primary-lt) !important;
}

#wic-app.wic-wrapper .wic-pill.active {
  background: var(--wic-primary) !important;
  border-color: var(--wic-primary) !important;
  color: #fff !important;
  box-shadow: 0 2px 10px rgba(13,148,136,0.3) !important;
}

#wic-app.wic-wrapper .wic-pill--season {
  flex: 1;
  padding: 10px 12px !important;
}

#wic-app.wic-wrapper .wic-pill-icon { font-size: 1rem; }

/* ── Text Inputs ────────────────────────────────────── */
#wic-app.wic-wrapper .wic-input-wrap { position: relative; }

#wic-app.wic-wrapper .wic-input {
  width: 100%;
  padding: 11px 48px 11px 14px;
  border: 1.5px solid var(--wic-border) !important;
  border-radius: 10px;
  font-family: 'DM Sans', sans-serif !important;
  font-size: 1rem;
  font-weight: 600;
  color: var(--wic-text);
  background: #f0fdfa !important;
  transition: all 0.2s;
  box-sizing: border-box;
  -moz-appearance: textfield;
  box-shadow: none !important;
  outline: none !important;
}

#wic-app.wic-wrapper .wic-input::-webkit-inner-spin-button,
#wic-app.wic-wrapper .wic-input::-webkit-outer-spin-button { -webkit-appearance: none; }

#wic-app.wic-wrapper .wic-input:focus {
  border-color: var(--wic-primary) !important;
  background: #fff !important;
  box-shadow: 0 0 0 3px rgba(13,148,136,0.15) !important;
  outline: none !important;
}

#wic-app.wic-wrapper .wic-input-unit {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--wic-muted);
  pointer-events: none;
}

/* ── Activity Dropdown ──────────────────────────────── */
#wic-app.wic-wrapper .wic-activity-select-wrap {
  position: relative;
}

#wic-app.wic-wrapper .wic-activity-select {
  width: 100%;
  padding: 12px 44px 12px 14px;
  border: 1.5px solid var(--wic-border) !important;
  border-radius: 10px;
  font-family: 'DM Sans', sans-serif !important;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--wic-text);
  background: #f0fdfa !important;
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
  transition: all 0.2s;
  box-sizing: border-box;
  box-shadow: none !important;
  outline: none !important;
}

#wic-app.wic-wrapper .wic-activity-select:focus {
  border-color: var(--wic-primary) !important;
  background: #fff !important;
  box-shadow: 0 0 0 3px rgba(13,148,136,0.15) !important;
  outline: none !important;
}

#wic-app.wic-wrapper .wic-activity-chevron {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  color: var(--wic-primary);
  width: 18px;
  height: 18px;
}

/* ── Submit Button ──────────────────────────────────── */
#wic-app.wic-wrapper .wic-submit {
  width: 100% !important;
  padding: 15px 20px !important;
  background: linear-gradient(135deg, #0d9488, #14b8a6) !important;
  border: none !important;
  border-radius: 12px !important;
  font-family: 'Cormorant', serif !important;
  font-size: 1.25rem !important;
  font-weight: 700 !important;
  font-style: italic !important;
  color: #fff !important;
  cursor: pointer;
  letter-spacing: 0.02em;
  transition: transform 0.25s, box-shadow 0.25s !important;
  box-shadow: 0 4px 16px rgba(13,148,136,0.38) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px;
  margin-top: 4px;
  text-shadow: none !important;
  outline: none !important;
  line-height: 1.2 !important;
  -webkit-appearance: none !important;
  appearance: none !important;
}

#wic-app.wic-wrapper .wic-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(13,148,136,0.48) !important;
  background: linear-gradient(135deg, #0f766e, #0d9488) !important;
  color: #fff !important;
}

#wic-app.wic-wrapper .wic-submit:active {
  transform: translateY(0);
}

#wic-app.wic-wrapper .wic-submit:focus {
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(13,148,136,0.35) !important;
}

@keyframes wic-spin { to { transform: rotate(360deg); } }

#wic-app.wic-wrapper .wic-spin {
  width: 18px; height: 18px;
  animation: wic-spin 0.8s linear infinite;
}

/* ── Result Panel ───────────────────────────────────── */
#wic-app.wic-wrapper .wic-result {
  padding: 32px;
  border-top: 1px solid var(--wic-border);
  animation: wic-fadein 0.5s ease;
}

@keyframes wic-fadein {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

#wic-app.wic-wrapper .wic-result-header {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 24px;
}

#wic-app.wic-wrapper .wic-result-drop {
  width: 72px; height: 88px;
  flex-shrink: 0;
  background: var(--wic-primary-lt);
  border-radius: 50% 50% 48% 48% / 40% 40% 60% 60%;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(13,148,136,0.22);
}

#wic-app.wic-wrapper .wic-result-fill {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  background: linear-gradient(to top, #0d9488, #5eead4);
  transition: height 1s cubic-bezier(0.34, 1.56, 0.64, 1);
  height: 0%;
}

#wic-app.wic-wrapper .wic-result-main { flex: 1; }

#wic-app.wic-wrapper .wic-result-label {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.75rem;
  color: var(--wic-muted);
  font-weight: 600;
  margin: 0 0 4px !important;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

#wic-app.wic-wrapper .wic-result-value {
  font-family: 'Cormorant', serif !important;
  font-size: 3.2rem !important;
  font-weight: 700 !important;
  font-style: italic !important;
  color: var(--wic-primary) !important;
  margin: 0 0 2px !important;
  line-height: 1;
  letter-spacing: -0.01em;
}

#wic-app.wic-wrapper .wic-result-unit {
  font-family: 'Cormorant', serif;
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--wic-accent);
}

#wic-app.wic-wrapper .wic-result-sub {
  font-size: 0.88rem;
  color: var(--wic-muted);
  margin: 0 !important;
  font-weight: 400;
}

/* ── Stats ──────────────────────────────────────────── */
#wic-app.wic-wrapper .wic-result-stats {
  display: flex;
  align-items: center;
  background: var(--wic-primary-lt);
  border-radius: 12px;
  padding: 16px;
  gap: 0;
  margin-bottom: 18px;
}

#wic-app.wic-wrapper .wic-stat {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}

#wic-app.wic-wrapper .wic-stat-val {
  font-family: 'Cormorant', serif !important;
  font-size: 1.5rem;
  font-weight: 700;
  font-style: italic;
  color: var(--wic-primary-dk);
}

#wic-app.wic-wrapper .wic-stat-lbl {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.68rem;
  color: var(--wic-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-align: center;
}

#wic-app.wic-wrapper .wic-stat-divider {
  width: 1px; height: 40px;
  background: rgba(13,148,136,0.2);
}

/* ── Tip ────────────────────────────────────────────── */
#wic-app.wic-wrapper .wic-tip {
  background: linear-gradient(135deg, #fef9c3, #fef08a);
  border-left: 3px solid #eab308;
  border-radius: 0 10px 10px 0;
  padding: 12px 16px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.84rem;
  color: #713f12;
  font-weight: 500;
  margin-bottom: 20px;
  line-height: 1.55;
}
#wic-app.wic-wrapper .wic-tip::before { content: '💡 '; }

/* ── Recalculate ────────────────────────────────────── */
#wic-app.wic-wrapper .wic-recalc {
  background: transparent !important;
  border: 1.5px solid var(--wic-border) !important;
  border-radius: 8px !important;
  padding: 10px 18px !important;
  font-family: 'DM Sans', sans-serif !important;
  font-size: 0.85rem !important;
  font-weight: 600 !important;
  color: var(--wic-muted) !important;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: none !important;
  text-shadow: none !important;
  -webkit-appearance: none !important;
  appearance: none !important;
  outline: none !important;
}

#wic-app.wic-wrapper .wic-recalc:hover {
  border-color: var(--wic-primary) !important;
  color: var(--wic-primary) !important;
  background: var(--wic-primary-lt) !important;
}

/* ── Error ──────────────────────────────────────────── */
#wic-app.wic-wrapper .wic-error {
  margin: 0 32px 24px;
  padding: 12px 16px;
  background: #fef2f2;
  border-left: 3px solid #ef4444;
  border-radius: 0 8px 8px 0;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.85rem;
  color: #991b1b;
  font-weight: 500;
}

/* ── Responsive: tablet ─────────────────────────────── */
@media (max-width: 600px) {
  #wic-app.wic-wrapper .wic-form   { padding: 22px 20px 26px; }
  #wic-app.wic-wrapper .wic-result { padding: 22px 20px; }
  #wic-app.wic-wrapper .wic-header { padding: 28px 20px 22px; }
  #wic-app.wic-wrapper .wic-error  { margin: 0 20px 20px; }
  #wic-app.wic-wrapper .wic-title  { font-size: 1.7rem !important; }
  #wic-app.wic-wrapper .wic-row    { grid-template-columns: 1fr; }
}

/* ── Responsive: phone ──────────────────────────────── */
@media (max-width: 420px) {
  #wic-app.wic-wrapper              { padding: 16px 10px; }
  #wic-app.wic-wrapper .wic-card   { border-radius: 18px; }
  #wic-app.wic-wrapper .wic-header { padding: 22px 16px 18px; }
  #wic-app.wic-wrapper .wic-form   { padding: 16px 14px 20px; gap: 16px; }
  #wic-app.wic-wrapper .wic-result { padding: 16px 14px; }
  #wic-app.wic-wrapper .wic-error  { margin: 0 14px 14px; }

  #wic-app.wic-wrapper .wic-title  { font-size: 1.45rem !important; }
  #wic-app.wic-wrapper .wic-pill   { padding: 6px 10px !important; font-size: 0.77rem !important; }

  #wic-app.wic-wrapper .wic-result-value  { font-size: 2.5rem !important; }
  #wic-app.wic-wrapper .wic-result-drop  { width: 58px; height: 72px; }
  #wic-app.wic-wrapper .wic-result-header { gap: 14px; }
  #wic-app.wic-wrapper .wic-stat-val { font-size: 1.2rem; }
}
