/* Theme custom overrides */

/* Hide plus/minus toggle spans in the main (desktop) header menu */
.header-area .navbar-nav .sub {
  display: none;
}

/*
 * Mobile / tablet side menu (dvLeft) overrides to match ayaninterior.com
 */

/* Make dropdown submenus behave like nested lists inside the off-canvas panel */
.dvLeft .dropdown-menu {
  position: static;
  float: none;
  display: none; /* controlled via JS slideToggle */
  margin: 0;
  padding: 0 0 0 15px;
  border: 0;
  box-shadow: none;
  background: transparent;
}

/* Ensure side-menu items look like original static nav */
.dvLeft .navigation ul.nav.flex-column > li.nav-item > a {
  display: block;
  padding: 8px 30px 8px 0;
}

/* Align plus/minus toggle icon on the right for parents with children */
.dvLeft .nav-item.mainDropdown > span.sub,
.dvLeft .nav-item.subDropdown > span.sub,
.dvLeft .menu-item-has-children > span.sub {
  position: absolute;
  top: 2px;
  right: 0;
  cursor: pointer;
  padding: 10px;
}

@media (max-width: 1199px) {
  .dvLeft .nav-item.mainDropdown > span.sub,
  .dvLeft .nav-item.subDropdown > span.sub,
  .dvLeft .menu-item-has-children > span.sub {
    color: #fff;
  }

  .dvLeft .nav-item.mainDropdown.open > span.sub,
  .dvLeft .nav-item.subDropdown.open > span.sub,
  .dvLeft .menu-item-has-children.open > span.sub {
    color: #fff;
  }
}

/* Hide Bootstrap dropdown caret icon for main navigation */
.header-area .navbar-nav .dropdown-toggle::after {
  display: none !important;
}

/* ---- Desktop navigation dropdowns ------------------------------------- *
 * The submenu opens on hover and on focus, so the parent link stays a normal
 * link and a section such as Residential can still be visited. Bootstrap's own
 * dropdown script is not used: it calls preventDefault() on the toggle link,
 * which is what stopped the section page being reachable.
 * The plus icon belongs to the off-canvas panel only.
 */
.header-area .navbar-nav li.nav-item > span.sub {
  display: none;
}

.header-area .navbar-nav .nav-link.has-children {
  position: relative;
  padding-right: 1.35rem;
}

.header-area .navbar-nav .nav-link.has-children::after {
  content: "";
  position: absolute;
  right: 0.45rem;
  top: 50%;
  width: 0;
  height: 0;
  margin-top: -2px;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  opacity: 0.75;
  transition: transform 0.15s ease-in-out;
}

.header-area .navbar-nav .dropdown:hover > .nav-link.has-children::after,
.header-area .navbar-nav .dropdown:focus-within > .nav-link.has-children::after {
  transform: rotate(180deg);
}

/* Bootstrap hides .dropdown-menu until .show, so hover has to reveal it. */
.header-area .navbar-nav .dropdown:hover > .dropdown-menu,
.header-area .navbar-nav .dropdown:focus-within > .dropdown-menu,
.header-area .navbar-nav .dropdown.open > .dropdown-menu {
  display: block;
}

/* A small bridge so the pointer can travel from the link down to the panel
   without the submenu closing on the way. */
.header-area .navbar-nav .dropdown > .dropdown-menu::before {
  content: "";
  position: absolute;
  top: -8px;
  left: 0;
  right: 0;
  height: 8px;
}

.header-area .navbar-nav .dropdown-menu .dropdown-menu {
  margin-top: -4px;
}

/* The submenu is a second level of the same bar, so it needs room and a
   readable width rather than Bootstrap's narrow default. A section with a
   dozen sub pages would otherwise run off the bottom of the screen, so the
   panel scrolls instead. */
.header-area .navbar-nav .dropdown-menu {
  min-width: 240px;
  max-height: 70vh;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 6px 0;
  border: 0;
  border-radius: 0;
  background: var(--site-secondary-color, #0f0f0e);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
}

.header-area .navbar-nav .dropdown-menu .dropdown-item,
.header-area .navbar-nav .dropdown-menu .nav-link {
  display: block;
  width: 100%;
  padding: 9px 20px;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
}

.header-area .navbar-nav .dropdown-menu .dropdown-item:hover,
.header-area .navbar-nav .dropdown-menu .dropdown-item:focus,
.header-area .navbar-nav .dropdown-menu .nav-link:hover,
.header-area .navbar-nav .dropdown-menu .nav-link:focus {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.header-area .navbar-nav .dropdown-menu .active > .nav-link {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}

/* The theme gives every .nav-item a ::before bar on hover, which would draw a
   stray line down the side of each submenu entry. */
.header-area .navbar-nav .dropdown-menu .nav-item > .nav-link::before {
  display: none;
}

/* Always show Owl Carousel dots in Clients slider */
.clients-slider .owl-dots {
  display: flex !important;
  justify-content: center;
  align-items: center;
  gap: 6px;
  margin-top: 20px;
}

/* Reset default Owl button appearance */
.clients-slider .owl-dot {
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
}

.clients-slider .owl-dot span {
  display: block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #000;      /* black dot */
  opacity: 0.3;          /* inactive = lighter */
}

.clients-slider .owl-dot.active span,
.clients-slider .owl-dot:hover span {
  background: #000;      /* active = black */
  opacity: 1;
}

/* ---- Page not found ------------------------------------------------- */

/* Sits between the banner and the footer, so the header and footer stay put and
   the page still reads as part of the site rather than a bare error. */
.not-found {
  padding-top: 20px;
}

.not-found .code {
  font-family: var(--font-family-Exo, "Exo", sans-serif);
  font-size: clamp(90px, 18vw, 190px);
  font-weight: 800;
  line-height: 0.9;
  color: var(--site-primary-color, #CA001B);
  /* A tint rather than a flat block, so the number reads as a watermark and the
     heading stays the thing the eye lands on. */
  opacity: 0.14;
  user-select: none;
}

.not-found .large-heading {
  margin-top: 10px;
  margin-bottom: 0;
  font-size: clamp(24px, 4vw, 40px);
  font-weight: 800;
  color: #191919;
}

.not-found p {
  margin: 14px auto 0;
  max-width: 52ch;
  font-size: 17px;
  line-height: 1.7;
  color: #5a5560;
}

.not-found .actions {
  margin-top: 28px;
}

/* The site's own button, so it follows the Primary colour without a rule of its
   own beyond the room its arrow needs. */
.not-found .actions .themeBtn {
  padding-left: 40px;
}

.not-found .quick-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 22px;
  margin: 40px auto 0;
  padding: 22px 0 0;
  max-width: 720px;
  list-style: none;
  border-top: 1px solid #e5e5e5;
}

.not-found .quick-links a {
  display: inline-block;
  padding: 4px 0;
  font-size: 15px;
  font-weight: 600;
  color: #2f2f2f;
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color 0.25s ease, border-color 0.25s ease;
}

.not-found .quick-links a:hover,
.not-found .quick-links a:focus-visible {
  color: var(--site-primary-color, #CA001B);
  border-bottom-color: currentColor;
  text-decoration: none;
}

@media (max-width: 575px) {
  .not-found p {
    font-size: 15px;
  }

  .not-found .quick-links {
    gap: 6px 16px;
  }
}

/* ---- Icons in the older "fa fa-name" style ---------------------------- */

/* The theme's markup asks for icons the Font Awesome 4 way, with a bare "fa"
   class naming the family. The icon font that ships is version 6, which dropped
   the rule that gave a bare .fa its family, so those 24 icons fell back to the
   version 4 face and most of them came out blank.
 *
 * The declarations are the ones Font Awesome 6 puts on its own family classes,
   so an icon looks the same whichever style it was written in. */
i.fa {
  -moz-osx-font-smoothing: grayscale;
  -webkit-font-smoothing: antialiased;
  display: var(--fa-display, inline-block);
  font-style: normal;
  font-variant: normal;
  line-height: 1;
  text-rendering: auto;
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
}

/* A glyph written on its own, with no family class, has no family to inherit and
   falls back to the page's own text font, which has no icon characters and draws
   a box. Solid is the only sensible family to assume for a bare name, which is
   what the older "fa fa-name" style meant.
 *
 * A brand glyph also begins "fa-", so this rule catches those too, and a brand
 * glyph is not in the solid font at all: asking for it there drew an empty box
 * and the brands face was never even fetched. The brands rule below therefore
 * has to come after this one, so that it is the rule that wins for a brand while
 * this one stays in charge of everything else. */
i[class*=" fa-"] {
  -moz-osx-font-smoothing: grayscale;
  -webkit-font-smoothing: antialiased;
  display: var(--fa-display, inline-block);
  font-style: normal;
  font-variant: normal;
  line-height: 1;
  text-rendering: auto;
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
}

i.fa-brands,
i.fab {
  font-family: "Font Awesome 6 Brands";
  font-weight: 400;
}

/* ---- The brand red, made to follow the admin's Primary colour --------- */

/* style.css writes the brand red straight into the rules below rather than
   reading it from a variable, so changing the Primary colour in Theme Colors
   moved the buttons and the links but left these behind on the old red. Each
   one is restated here against --site-primary-color, which the admin does
   drive. Only the declarations that needed !important to win in the first place
   keep it, and the fallbacks are the values being replaced. */

.site-logo::before {
  background-color: var(--site-primary-color, #CA001B);
}

/* The two white discs that sit on the disc's own edge, drawn as a hairline of
   the brand colour. */
.credibility-box .icon,
.why-choose-grid .why-choose-box .icon {
  box-shadow: 0 1px 0 rgba(var(--site-primary-rgb, 202, 0, 27), 0.32);
}

/* The tick beside each item in the list over the hero slider, which the theme
   drew a shade brighter than the brand colour. */
ul.slider-mark li a::before {
  color: var(--site-primary-color, #CA001B);
}

/* The play button over the overview image, and the triangle inside it. The play
   button already carried an !important, so the override needs one too. */
.video-butn {
  color: var(--site-primary-color, #CA001B) !important;
}

.overview-img-holder a.video-butn .triangle {
  stroke: var(--site-primary-color, #CA001B);
}

/* A service card: the folded corner and the arrow that turns white on hover. */
a.service-icon svg,
a.service-icon i {
  color: var(--site-primary-color, #CA001B);
}

.service-card:hover .service-icon {
  background-color: var(--site-primary-color, #CA001B);
}

/* The rule that draws itself across the card on hover, translucent so the card
   shows through. */
.service-text::before {
  background-color: rgba(var(--site-primary-rgb, 202, 0, 27), 0.53);
}

.service-content h3 a {
  color: var(--site-primary-color, #CA001B);
}

/* The glyph inside the round disc in Why Choose, which the theme drew a shade
   darker than the brand colour. */
.why-choose-grid .why-choose-box .icon svg,
.why-choose-grid .why-choose-box .icon img {
  color: var(--site-primary-color, #CA001B);
}

/* The number in the corner of a work process step. */
.steps-number {
  background-color: var(--site-primary-color, #CA001B);
}

/* Buttons and form submits the theme coloured itself rather than leaving them
   to .themeBtn. */
.slider-text .theme-btn:hover {
  color: var(--site-primary-color, #CA001B) !important;
}

table#review tr:last-child td input {
  background-color: var(--site-primary-color, #CA001B) !important;
}

.allPageForm .dvForm .form-item:last-child input[type="submit"] {
  background: var(--site-primary-color, #CA001B);
}

.cta-contact {
  background-color: var(--site-primary-color, #CA001B);
}

/* ---- The other reds in the theme, made to follow the Primary colour -- */

/* style.css writes four more reds in directly rather than reading a variable:
   the wide active dot under the hero slider, the breadcrumb's own page, the bar
   beside a call to action heading, and the two shapes behind a project
   thumbnail. They are branding, so they follow the Primary colour the same way
   the block above does. The hover a dropdown entry takes is branding too. */

/* The wide dot marking the current slide. */
.swiper-pagination-bullet-active {
  background: var(--site-primary-color, #ff0022) !important;
}

/* The breadcrumb's own page, which the theme drew a shade off the brand red. */
.breadcrumb li.active em {
  color: var(--site-primary-color, #ff1b3a) !important;
}

/* The bar that sits to the left of a call to action heading. */
.cta-left span::before {
  background-color: var(--site-primary-color, #ff0000);
}

/* The circle that grows in behind a project thumbnail, and the bar that floats
   up and down behind its second image. */
.fancy-image::before {
  background-color: var(--site-primary-color, #ff0000);
}

.img-wrapper::before {
  background-color: var(--site-primary-color, #ff0000);
}

/* A dropdown entry and its caret on hover. Only the colour is restated, so the
   nudge the theme gives the entry is left alone. */
.navbar-light .navbar-nav .dropdown-menu a:hover,
.navbar-nav > li.dropdown .dropdown-menu li.dropdown:hover > a {
  color: var(--site-primary-color, #ff0000);
}

.navbar-nav > li.dropdown .dropdown-menu li.dropdown > a:hover::after,
.navbar-nav > li.dropdown .dropdown-menu li.dropdown:hover > a::after {
  color: var(--site-primary-color, #ff0000);
}

/* Left on purpose: the required field asterisk, the inline field error, the
   reCAPTCHA error and the theme's own .error are also red in style.css. They
   are a signal rather than a brand, so painting them the brand colour would stop
   them reading as an error, and would hide them outright on a form if the
   Primary colour were set to white. */

/* ---- The floating message button ------------------------------------- */

/* One round button fixed to the right of the page, which opens three channels
   upwards. Everything an admin can change arrives as a custom property, so this
   block never has to be edited to move or recolour the widget. */
.ayan-float {
  position: fixed;
  right: var(--ayan-float-edge, 24px);
  bottom: var(--ayan-float-edge, 24px);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.ayan-float-list {
  position: absolute;
  right: 0;
  bottom: calc(100% + 12px);
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

/* Closed, each channel sits on the button and is not clickable. --d is set per
   row in the view, counting down from the one nearest the button, so opening
   travels upwards. */
.ayan-float-item {
  display: flex;
  align-items: center;
  opacity: 0;
  transform: translateY(14px) scale(0.8);
  pointer-events: none;
  transition: opacity 0.26s ease,
              transform 0.34s cubic-bezier(0.34, 1.4, 0.64, 1);
  transition-delay: calc(var(--d, 0) * 70ms);
}

.ayan-float.is-open .ayan-float-item {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.ayan-float-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  /* The right padding is half the difference between the button and the icon,
     so the three round icons sit on the same centre line as the button below
     them and the row reads as one control. */
  padding: 5px 8px 5px 14px;
  border-radius: 999px;
  background: #fff;
  color: #1f2937;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ayan-float-link:hover,
.ayan-float-link:focus-visible {
  transform: translateX(-4px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28);
  color: #1f2937;
  text-decoration: none;
}

.ayan-float-label {
  font-family: var(--font-family-Exo, "Exo", sans-serif);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
}

.ayan-float-icon {
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--ayan-channel, #ca001b);
  color: #fff;
  font-size: 17px;
}

.ayan-float-icon i {
  color: #fff !important;
}

.ayan-float-toggle {
  position: relative;
  width: 58px;
  height: 58px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--ayan-float-colour, var(--site-primary-color, #ca001b));
  color: #fff;
  font-size: 23px;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.3);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.ayan-float-toggle:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.34);
}

.ayan-float-toggle:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 3px;
}

/* A slow ring while the button is closed, to catch the eye without moving
   anything. It stops as soon as the channels are open. */
.ayan-float-toggle::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid currentColor;
  opacity: 0;
  animation: ayan-float-pulse 2.4s ease-out infinite;
}

.ayan-float.is-open .ayan-float-toggle::after {
  animation: none;
}

@keyframes ayan-float-pulse {
  0%   { transform: scale(1);    opacity: 0.55; }
  70%  { transform: scale(1.45); opacity: 0; }
  100% { transform: scale(1.45); opacity: 0; }
}

.ayan-float-glyph--open {
  display: none;
}

.ayan-float.is-open .ayan-float-glyph--closed {
  display: none;
}

.ayan-float.is-open .ayan-float-glyph--open {
  display: inline-block;
}

.ayan-float-bubble {
  position: absolute;
  right: calc(100% + 12px);
  top: 50%;
  transform: translateY(-50%);
  padding: 7px 14px;
  border-radius: 999px;
  background: #fff;
  color: #1f2937;
  font-family: var(--font-family-Exo, "Exo", sans-serif);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
  animation: ayan-float-bubble-in 0.5s ease 0.5s both;
}

/* The three labels say the same thing the channel icons do, so the bubble
   would only crowd them. */
.ayan-float.is-open .ayan-float-bubble {
  display: none;
}

@keyframes ayan-float-bubble-in {
  0%   { opacity: 0; transform: translate(-8px, -50%); }
  100% { opacity: 1; transform: translate(0, -50%); }
}

.ayan-float--hidden-small {
  display: none;
}

@media (max-width: 575px) {
  /* On a phone the channel pills would run off the left edge. */
  .ayan-float:not(.ayan-float--hidden-small) {
    right: calc(var(--ayan-float-edge, 24px) / 2);
    bottom: calc(var(--ayan-float-edge, 24px) / 2);
  }

  .ayan-float:not(.ayan-float--hidden-small) .ayan-float-label,
  .ayan-float:not(.ayan-float--hidden-small) .ayan-float-bubble {
    display: none;
  }

  /* With no label the pill is just the icon, and this padding makes it the same
     58px circle as the button above it. */
  .ayan-float:not(.ayan-float--hidden-small) .ayan-float-link {
    padding: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ayan-float-item,
  .ayan-float-link,
  .ayan-float-toggle {
    transition: none;
  }

  .ayan-float-toggle::after,
  .ayan-float-bubble {
    animation: none;
  }

  .ayan-float-bubble {
    opacity: 1;
    transform: translateY(-50%);
  }
}

/* ---------------------------------------------------------------------------
   A quick link with a label but no destination
   ---------------------------------------------------------------------------
   The list over the hero slider is a list of links, and the theme draws an arrow
   in front of every item to say so. An editor who fills in a label and leaves the
   destination empty has not made a link, and giving them one that goes nowhere
   when clicked is a promise the site cannot keep - the arrow would say "this goes
   somewhere" and the click would do nothing.

   So that item is written as plain text instead, in the same place and at the
   same sizes as the links around it so the row still lines up, but without the
   arrow and without the underline, and a shade quieter so it does not read as
   something to click. The sizes follow the theme's own breakpoints for the links
   it sits beside. */
ul.slider-mark li span {
  color: #fff;
  display: inline-flex;
  align-items: center;
  font-size: 18px;
  font-weight: 400;
  opacity: 0.72;
}

@media (max-width: 991px) {
  ul.slider-mark li span {
    font-size: 16px;
  }
}

@media (max-width: 767px) {
  ul.slider-mark li span {
    font-size: 15px;
  }
}

/* ---------------------------------------------------------------------------
   The small picture in the Why Choose section
   ---------------------------------------------------------------------------
   The theme states the sizes of the two pictures here only as attributes on the
   tag - width="215" height="280" - and those do nothing. Its own stylesheet
   carries the bootstrap reboot rule

       img { width: auto; height: auto; max-width: 100% }

   and a CSS width beats an attribute, so every picture on the site is drawn at
   whatever size the file happens to be, held inside its column by max-width.

   The bundled file is exactly 215 x 280, which is why the section looked right
   before anything was uploaded: the file matched the number in the tag. An
   uploaded picture is whatever the editor's phone produced, so a 1200 x 880 file
   drew at 470 x 345 and a 3000 x 4000 one at 470 x 627 - far bigger than the
   design, and larger than the picture it is meant to sit beside.

   The size is stated here instead, so the frame is the design's whatever the
   file is. cover rather than fill, so a picture of another shape is cropped to
   the frame instead of stretched out of proportion. max-width so it still gives
   way on a narrow screen.
   --------------------------------------------------------------------------- */

.img-wrapper .second-img img {
  width: 215px;
  height: 280px;
  max-width: 100%;
  object-fit: cover;
  object-position: center;
}
