/*
 * nomitech.gr additions on top of the nomitech.com stylesheets (webflow.css, site.css: copied from
 * the nomitech.com repository, keep them identical). Colours come from the theme variables, so dark mode works.
 */

/* ---- Greek in headings ----
 * The heading font (Sora) has no Greek letters. The heading font stack puts Inter (the body font, which has them)
 * right after Sora, so Greek letters in headings come from Inter and Latin text stays Sora, as on nomitech.com.
 * (A second @font-face for Sora with a Greek unicode-range, with a different weight range than the original in
 * webflow.css, made browsers drop Sora for Latin text too: it fell back to Arial.) */
:root {
  --fonts--heading: 'Sora [variable]', 'Inter [variable]', sans-serif;
}

/* ---- Nav ---- */
/* Colour logos on the dark product cards: show them white. */
.nav_dropdown-card-image-logo.is-tinted,
.gr-product-card_logo.is-tinted {
  filter: brightness(0) invert(1);
}
.nav_dropdown-card-image-logo {
  width: auto;
  max-width: 70%;
  max-height: 2.5rem;
  object-fit: contain;
}
/* A dropdown with links only (Υποστήριξη). */
.nav_dropdown-desktop-content.is-links-only {
  grid-template-columns: 1fr;
}
@media (min-width: 992px) {
  .nav_dropdown-list.is-small .nav_dropdown-content-wrapper {
    width: auto;
    min-width: 18rem;
  }
}

/* ---- Footer: address under the logo ---- */
/* The logo link floats (Webflow .w-nav-brand). */
.footer_logo-link-wrapper > :not(.footer_logo-link) {
  clear: both;
}
.footer_contact {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.7;
  opacity: 0.8;
}

/* ---- Hero ---- */
.gr-hero_actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
}
.gr-hero_logo {
  display: block;
  width: auto;
  max-width: 14rem;
  max-height: 4rem;
  object-fit: contain;
}
.gr-plain-text p {
  margin: 0;
}

/* Large photo under the hero (page template). */
.gr-wide-image {
  display: block;
  width: 100%;
  max-height: 34rem;
  object-fit: cover;
  border-radius: 1rem;
}

/* Long hero headings (product pages): one size down. */
.gr-hero_heading-long {
  font-size: 3rem;
  line-height: 1.15;
}
@media (max-width: 767px) {
  .gr-hero_heading-long {
    font-size: 2.25rem;
  }
}

/* ---- Product gallery: equal tiles, up to three per row (screenshots are shown whole) ---- */
.gr-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.gr-gallery.is-1 {
  grid-template-columns: minmax(0, 48rem);
  justify-content: center;
}
.gr-gallery.is-2,
.gr-gallery.is-4 {
  grid-template-columns: repeat(2, 1fr);
}
.gr-gallery_item {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  padding: 1rem;
  border-radius: 1rem;
  border: 1px solid var(--color--border);
  background-color: #fff;
}
@media (max-width: 767px) {
  .gr-gallery,
  .gr-gallery.is-2,
  .gr-gallery.is-4 {
    grid-template-columns: 1fr;
  }
}

/* ---- Home: services ---- */
.gr-services {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.gr-service-card {
  padding: 2rem;
  border-radius: 1rem;
  border: 1px solid var(--color--border);
  background-color: var(--color--surface-secondary);
  color: var(--color--on-surface-secondary);
}
.gr-service-card_icon {
  width: 2.75rem;
  height: 2.75rem;
  margin-bottom: 1.25rem;
  color: var(--color--brand-blue);
}
@media (max-width: 991px) {
  .gr-services {
    grid-template-columns: 1fr;
  }
}

/* ---- Product cards ---- */
.gr-products {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.gr-products.is-4-col {
  grid-template-columns: repeat(4, 1fr);
}
@media (max-width: 991px) {
  .gr-products,
  .gr-products.is-4-col {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 479px) {
  .gr-products,
  .gr-products.is-4-col {
    grid-template-columns: 1fr;
  }
}
.gr-product-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 1rem;
  border: 1px solid var(--color--border);
  background-color: var(--color--surface-secondary);
  color: var(--color--on-surface-primary);
  text-decoration: none;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}
.gr-product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
}
.gr-product-card_media {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #0b1440, #1d2fd6);
}
.gr-product-card_image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.gr-product-card_overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(5, 8, 30, 0.35), rgba(5, 8, 30, 0.75));
}
.gr-product-card_logo {
  position: relative;
  width: auto;
  max-width: 60%;
  max-height: 3.5rem;
  object-fit: contain;
}
.gr-product-card_logo-text {
  position: relative;
  color: #fff;
  font-family: var(--fonts--heading, 'Sora [variable]'), sans-serif;
  font-size: 1.75rem;
  font-weight: 600;
}
.gr-product-card_body {
  padding: 1.5rem;
}
.gr-product-card_body p {
  margin-top: 0.5rem;
}

/* ---- Call to action card ---- */
.gr-cta_card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: 3rem;
  border-radius: 1.5rem;
  color: #fff;
  background:
    radial-gradient(circle at 85% 20%, rgba(76, 99, 255, 0.55), transparent 55%),
    linear-gradient(135deg, #070b24, #14207a);
}
.gr-cta_card h2 {
  color: #fff;
}
.gr-cta_text {
  max-width: 40rem;
  color: rgba(255, 255, 255, 0.8);
}
.gr-home-contact ul {
  margin: 0.5rem 0 0;
  padding-left: 1.2rem;
}
.gr-home-contact p {
  margin: 0;
}
.gr-home-contact a {
  color: #fff;
}
@media (max-width: 767px) {
  .gr-cta_card {
    padding: 2rem 1.5rem;
  }
}

/* ---- Contact ---- */
.gr-contact-details p {
  margin: 0 0 1rem;
}
.gr-contact-details a {
  color: inherit;
}
.gr-map {
  display: block;
  width: 100%;
  height: 22rem;
  border: 0;
  border-radius: 1rem;
}

/* ---- Video (Markdown <div class="video"> and the home page) ---- */
.video {
  position: relative;
  aspect-ratio: 16 / 9;
  width: 100%;
  margin: 0 auto 2rem;
  overflow: hidden;
  border-radius: 1rem;
  background-color: #000;
}
.video iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.gr-video {
  margin-bottom: 0;
}

/* ---- Article text ---- */
/* Images in page text (logos, photos): no full-width stretch, centred. */
.section_gr-content .rich-text_blog-article img {
  max-height: 28rem;
  width: auto;
}

/* ---- Page text: the nomitech.com scale ----
 * .rich-text_blog-article is the blog-article style of nomitech.com (19px text with 36px line height, 38px
 * sub-headings). The pages here use the sizes of the rest of the site instead: body text like .text-size-medium,
 * sub-headings like .heading-style-h4 / h5. */
.section_gr-content .rich-text_blog-article p,
.section_gr-content .rich-text_blog-article li {
  font-size: var(--text-size--l);
  line-height: 1.7;
}
.section_gr-content .rich-text_blog-article h2,
.section_gr-content .rich-text_blog-article h3 {
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  padding-top: 0;
  padding-bottom: 0;
}
.section_gr-content .rich-text_blog-article h2 {
  font-size: var(--heading-h4--size);
  line-height: var(--heading-h4--line-height);
}
.section_gr-content .rich-text_blog-article h3 {
  font-size: var(--heading-h5--size);
  line-height: var(--heading-h5--line-height);
}
.section_gr-content .rich-text_blog-article > :first-child {
  margin-top: 0;
}

/* ---- Product pages: lead paragraph, feature lists as cards with a check mark ---- */
.section_gr-content.is-product .rich-text_blog-article > p:first-child {
  font-size: var(--text-size--xl);
  line-height: 1.65;
}
.section_gr-content.is-product .rich-text_blog-article ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 1.25rem 0 2rem;
  padding: 0;
  list-style: none;
}
.section_gr-content.is-product .rich-text_blog-article ul > li {
  position: relative;
  margin: 0;
  padding: 1rem 1.25rem 1rem 3.25rem;
  border: 1px solid var(--color--border);
  border-radius: 0.75rem;
  background-color: var(--color--surface-secondary);
  font-size: var(--text-size--m);
  font-weight: 500;
  line-height: 1.45;
}
.section_gr-content.is-product .rich-text_blog-article ul > li::before {
  content: '';
  position: absolute;
  top: 1rem;
  left: 1.1rem;
  width: 1.4rem;
  height: 1.4rem;
  background-color: var(--color--brand-blue);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20Zm4.7 7.7-5.5 5.5a1 1 0 0 1-1.4 0l-2.5-2.5a1 1 0 1 1 1.4-1.4l1.8 1.8 4.8-4.8a1 1 0 1 1 1.4 1.4Z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20Zm4.7 7.7-5.5 5.5a1 1 0 0 1-1.4 0l-2.5-2.5a1 1 0 1 1 1.4-1.4l1.8 1.8 4.8-4.8a1 1 0 1 1 1.4 1.4Z'/%3E%3C/svg%3E") center / contain no-repeat;
}
@media (max-width: 767px) {
  .section_gr-content.is-product .rich-text_blog-article ul {
    grid-template-columns: 1fr;
  }
}

/* ---- Product gallery: screenshots on a white band, each on a card ---- */
.gr-gallery_item {
  background-color: var(--color--surface-primary);
  box-shadow: 0 1px 2px rgba(10, 13, 40, 0.06);
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}
.gr-gallery_item:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(10, 13, 40, 0.12);
}

/* ---- Footer: five even columns (address, company, products, partner solutions, support) ---- */
.footer_contact {
  font-size: 0.9375rem;
  line-height: 1.8;
}
@media (min-width: 992px) {
  .footer_links-wrapper {
    grid-template-columns: minmax(0, 1.5fr) repeat(4, minmax(0, 1fr));
  }
}

/* ---- Hero logo on the dark hero: colour logos are shown white ---- */
.gr-hero_logo.is-tinted {
  filter: brightness(0) invert(1);
}
.gr-content-image {
  padding-bottom: 0;
}

/* ---- Product hero (ProductHero.astro, as nomitech.com/costos) ---- */
.product-hero_logo-image {
  max-width: min(22rem, 100%);
}
.product-hero_logo-image.is-tinted {
  filter: brightness(0) invert(1);
}
.gr-product-hero_name {
  margin: 0;
  color: #fff;
  font-family: var(--fonts--heading);
  font-size: var(--heading-h2--size);
  font-weight: 600;
  line-height: 1.1;
}
.gr-product-hero_heading {
  color: #fff;
}
.gr-product-hero_text p {
  margin: 0;
}

/* ---- Συνεργασίες (partners page): one block per partner, logos at a readable size ---- */
.page-partners .rich-text_blog-article h3 {
  margin-top: 3rem;
  padding-top: 3rem;
  border-top: 1px solid var(--color--border);
}
.page-partners .rich-text_blog-article h3:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}
.page-partners .rich-text_blog-article p:has(> img:only-child) {
  text-align: left;
  margin-top: 1.5rem;
}
.page-partners .rich-text_blog-article img {
  max-height: 6rem;
  width: auto;
}

/* Footer social icons in one row, also on phones. */
.footer_social-icons-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
}
