:root{
  --bg: #f6f7fb;
  --card: rgba(255,255,255,0.86);
  --card-solid: #ffffff;
  --stroke: rgba(0,0,0,0.08);
  --shadow: 0 10px 30px rgba(0,0,0,0.08);
  --shadow-soft: 0 6px 18px rgba(0,0,0,0.08);

  --text: #121826;
  --muted: rgba(18,24,38,0.65);

  --red: #d62828;
  --red-2: #c81d25;
  --green: #2f9e44;
  --amber: #f59f00;

  --radius-xl: 26px;
  --radius-lg: 18px;
  --radius-md: 12px;

  --maxw: 980px;
  --maxw-wide: 1180px;

  --font: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji";

  /* Polish pack variables */
  --page-pad: 18px;
  --field-h: 46px;
  --card-pad: 20px;
  --title: 22px;
  --sub: 13px;
  --glass: rgba(255,255,255,0.82);
  --glass-2: rgba(255,255,255,0.72);
  --ring: rgba(214,40,40,0.14);

  /* TEDES base red for background */
  --tedes-red-1: #b51f1f;
  --tedes-red-2: #8f1a1a;
  --tedes-red-3: #6e1414;
}

*{ box-sizing:border-box; }
html, body{ height:100%; }
body{
  margin:0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
}

/* ===== FULL-PAGE BACKGROUND (uses your image everywhere) ===== */

/* Σβήνουμε το κόκκινο gradient που γέμιζε κάτω μέρος */
body::before{
  content:none !important;
}

.app-bg{
  position: fixed;
  inset: 0;              /* ✅ καλύπτει όλη την οθόνη */
  z-index: -3;

  background:
    linear-gradient(rgba(0,0,0,0.28), rgba(0,0,0,0.0)),
    url("../assets/bg-awning-A.jpg") center 60% / cover no-repeat;

  filter: blur(6px);
  transform: scale(1.04);
}

@media (min-width: 1200px){
  .app-bg{ background-size: 140% auto; }
}

@media (max-width: 600px){
  .app-bg{
    height: 240px;
    background-size: 160% auto;
  }
}

/* If you ever want NO background at all on a page */
.app-no-bg{
  background: var(--bg);
}

/* Layout */
.container{
  width: min(var(--maxw), calc(100% - 24px));
  margin: 0 auto;
  padding: 16px 0 34px;
}

.topbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 12px;
  padding: 10px 0 12px;
}

.brand{
  display:flex;
  align-items:center;
  gap: 12px;
  min-width: 0;
}
.brand img{
  width: 56px;
  height: 56px;
  object-fit: contain;
  border-radius: 14px;
  box-shadow: var(--shadow-soft);
  background: #fff;
}
.brand .title{
  display:flex;
  flex-direction:column;
  line-height:1.1;
  min-width: 0;
}
.brand .title strong{
  font-size: 16px;
}
.brand .title span{
  font-size: 12px;
  color: rgba(255,255,255,0.85);
}

/* On light pages you can override span color inline if needed */
.pill{
  display:inline-flex;
  align-items:center;
  gap:10px;
  padding: 10px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.35);
  background: rgba(255,255,255,0.20);
  box-shadow: 0 10px 24px rgba(0,0,0,0.12);
  backdrop-filter: blur(10px);
  color: #fff;
}

.card{
  position: relative;
  overflow: hidden;
  background: var(--glass);
  border: 1px solid rgba(255,255,255,0.42);
  box-shadow: 0 16px 50px rgba(0,0,0,0.10);
  border-radius: var(--radius-xl);
  backdrop-filter: blur(12px);
}
/* “Hero” top glow */
.card::before{
  content:"";
  position:absolute;
  inset: 0;
  border-radius: var(--radius-xl);
  pointer-events:none;
  background: radial-gradient(900px 260px at 20% 0%,
    rgba(214,40,40,0.10),
    rgba(255,255,255,0.00) 60%);
  opacity: 1;
}

.card-inner{
  padding: var(--card-pad);
  position: relative;
}

.h1{
  font-size: var(--title);
  letter-spacing: -0.2px;
  margin: 0 0 6px;
  color: #111;
}
.p{
  margin: 0 0 14px;
  color: rgba(18,24,38,0.68);
  font-size: var(--sub);
  line-height: 1.45;
}

/* Sections */
.section{
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(0,0,0,0.05);
}
.section:first-child{
  margin-top:0;
  padding-top:0;
  border-top:none;
}

.section-title{
  display:flex;
  align-items:center;
  gap: 10px;
  margin-bottom: 10px;
  font-weight: 900;
  color: var(--red);
}
.section-title::before{
  content:"";
  width: 4px;
  height: 18px;
  border-radius: 99px;
  background: var(--red);
  box-shadow: 0 6px 14px rgba(214,40,40,0.25);
}

/* Grid */
.grid{
  display:grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 12px;
}
.col-12{ grid-column: span 12; }
.col-6{ grid-column: span 6; }
.col-4{ grid-column: span 4; }
.col-3{ grid-column: span 3; }
.col-8{ grid-column: span 8; }

@media (max-width: 860px){
  .col-6, .col-4, .col-3, .col-8{ grid-column: span 12; }
  .brand img{ width: 52px; height: 52px; }
}

/* Fields */
.field label{
  display:block;
  font-size: 12px;
  color: rgba(18,24,38,0.65);
  margin: 0 0 6px;
}
.input, .select, .textarea{
  width:100%;
  border: 1px solid rgba(0,0,0,0.10);
  background: rgba(255,255,255,0.86);
  border-radius: 14px;
  outline: none;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.8);
  font-family: var(--font); /* ✅ σιγουρεύει ίδια γραμματοσειρά */
}
.input, .select{
  height: var(--field-h);
  padding: 0 14px;
}
.textarea{
  min-height: 90px;
  resize: vertical;
  padding: 12px 14px;
}
.input:focus, .select:focus, .textarea:focus{
  border-color: rgba(214,40,40,0.38);
  box-shadow: 0 0 0 5px var(--ring);
}
.hint{
  margin-top: 6px;
  font-size: 12px;
  color: rgba(18,24,38,0.62);
}
.error{
  margin-top: 6px;
  font-size: 12px;
  color: #b10024;
}

/* Buttons */
.actions{
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
  margin-top: 14px;
}
.btn{
  border: none;
  border-radius: 999px;
  padding: 10px 14px;
  cursor: pointer;
  font-weight: 900;
  box-shadow: 0 8px 18px rgba(0,0,0,0.10);
  border: 1px solid rgba(0,0,0,0.10);
  background: rgba(255,255,255,0.86);
  color: var(--text);
  transition: transform 120ms ease, box-shadow 120ms ease, filter 120ms ease;
  font-family: var(--font); /* ✅ */
}
.btn:hover{
  filter: brightness(1.02);
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.12);
}
.btn:active{
  transform: translateY(1px);
  box-shadow: 0 6px 14px rgba(0,0,0,0.08);
}

.btn-primary{
  background: linear-gradient(180deg, var(--red), var(--red-2));
  color: #fff;
  border-color: rgba(255,255,255,0.25);
}
.btn-ghost{
  background: rgba(255,255,255,0.74);
}
.btn-danger{
  background: linear-gradient(180deg, #ef233c, #d90429);
  color: #fff;
}
.btn-success{
  background: linear-gradient(180deg, #37b24d, #2f9e44);
  color: #fff;
}
.btn-small{ padding: 8px 12px; font-size: 13px; }

.btn.disabled {
  pointer-events: none;
  opacity: 0.6;
  cursor: not-allowed;
}

/* Sticky actions */
.sticky-actions{
  position: sticky;
  bottom: 10px;
  margin-top: 14px;
  padding: 10px;
  border-radius: var(--radius-xl);
  background: rgba(255,255,255,0.70);
  border: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 16px 40px rgba(0,0,0,0.12);
  backdrop-filter: blur(12px);
}
@media (min-width: 860px){
  .sticky-actions{
    position: static;
    background: transparent;
    border: none;
    box-shadow:none;
    padding:0;
  }
}
@media (max-width: 860px){
  .sticky-actions{
    padding: 8px;
    border-radius: 22px;
  }
  .actions{ justify-content: stretch; }
  .actions .btn, .actions a.btn{ flex: 1; text-align:center; }
}

/* Table (desktop) */
.table-wrap{
  overflow:auto;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(0,0,0,0.08);
  background: rgba(255,255,255,0.72);
}
table{
  width:100%;
  border-collapse: collapse;
  min-width: 760px;
}
th, td{
  padding: 10px 12px;
  border-bottom: 1px solid rgba(0,0,0,0.06);
  font-size: 13px;
}
th{
  text-align:left;
  color: rgba(18,24,38,0.75);
  background: rgba(255,255,255,0.55);
  position: sticky;
  top: 0;
  z-index: 1;
}
td .row-actions{
  display:flex;
  gap: 8px;
  justify-content:flex-end;
}

/* Mobile: customers table -> cards */
@media (max-width: 860px){
  .table-wrap{
    border: none;
    background: transparent;
  }
  table{
    min-width: 0;
    border-collapse: separate;
    border-spacing: 0 10px;
  }
  thead{ display:none; }
  tr{
    display:block;
    background: var(--glass-2);
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: 18px;
    box-shadow: 0 10px 22px rgba(0,0,0,0.08);
    padding: 10px;
  }
  td{
    display:block;
    border: none;
    padding: 6px 8px;
  }
  td:last-child{ padding-top: 10px; }
  td .row-actions{ justify-content:flex-start; flex-wrap:wrap; }
}

/* Badges */
.badge{
  display:inline-flex;
  align-items:center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  font-weight: 900;
  font-size: 12px;
  border: 1px solid rgba(0,0,0,0.08);
  background: rgba(255,255,255,0.78);
}
.badge-ok{ color: #1b5e20; }
.badge-warn{ color: #7a4b00; }

/* Multi-select */
.ms{ position: relative; }
.ms-btn{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 10px;
  cursor:pointer;
}
.ms-tags{
  display:flex;
  flex-wrap:wrap;
  gap: 6px;
}
.tag{
  display:inline-flex;
  align-items:center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(214,40,40,0.10);
  border: 1px solid rgba(214,40,40,0.25);
  font-size: 12px;
  font-weight: 900;
}
.ms-menu{
  position:absolute;
  left:0; right:0;
  top: calc(100% + 8px);
  background: rgba(255,255,255,0.95);
  border: 1px solid rgba(0,0,0,0.10);
  border-radius: 16px;
  box-shadow: 0 18px 40px rgba(0,0,0,0.14);
  padding: 10px;
  display:none;
  z-index: 20;

  /* ✅ Scroll */
  max-height: 260px;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
.ms-menu.open{ display:block; }
.ms-item{
  display:flex;
  align-items:center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 12px;
}
.ms-item:hover{ background: rgba(0,0,0,0.04); }
.ms-item input{ transform: scale(1.1); }

/* ✅ FINAL: ΕΝΙΑΙΑ ΓΡΑΜΜΑΤΟΣΕΙΡΑ/ΜΕΓΕΘΟΣ για ΟΛΟ το multi-select
   (λύνει το "φαίνεται άλλη γραμματοσειρά") */
.ms,
.ms-btn,
.ms-tags,
.ms-menu,
.ms-item,
.ms-item span,
.ms-item input{
  font-family: var(--font) !important;
  font-size: 14px !important;
  font-weight: 500;
}

/* Print view */
.print-grid{
  display:grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
.project-item{
  background: rgba(255,255,255,0.78);
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 18px;
  padding: 12px;
  box-shadow: 0 10px 22px rgba(0,0,0,0.10);
}
.project-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap: 10px;
}
.project-title{ font-weight: 950; }
.project-meta{
  margin-top: 6px;
  font-size: 13px;
  color: rgba(18,24,38,0.65);
  display:grid;
  gap: 4px;
}
.mapframe{
  width:100%;
  height: 220px;
  border: 0;
  border-radius: 16px;
  margin-top: 10px;
  background: #fff;
}

/* Helpers */
.center{
  display:flex;
  align-items:center;
  justify-content:center;
}

/* Login */
.login-wrap{
  width: min(460px, calc(100% - 24px));
  margin: 0 auto;
  padding: 32px 0 24px;
}
.google-box{
  display:flex;
  flex-direction:column;
  gap: 10px;
  align-items:center;
  padding: 14px;
  border-radius: var(--radius-lg);
  background: rgba(255,255,255,0.70);
  border: 1px solid rgba(0,0,0,0.08);
}

.small-note{
  font-size: 12px;
  color: rgba(18,24,38,0.62);
  text-align:center;
}

/* Topbar compact on mobile */
@media (max-width: 560px){
  .topbar{ flex-direction: column; align-items: stretch; gap: 10px; }
  .pill{ width: 100%; justify-content: space-between; }
}
