/*
Theme Name: Aviation Security
Theme URI:  https://github.com/Ratt-Grafiska/aviation-security
Update URI:  https://github.com/Ratt-Grafiska/aviation-security
Author: Rätt Grafiska AB
Author URI: https://rattgrafiska.se
Description: Theme for Aviation Security
Requires at least: 6.8
Tested up to: 6.8
Requires PHP: 7.2
Version: 2025.09.18.03
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: aviation-security


/*
 * Link styles
 * https://github.com/WordPress/gutenberg/issues/42319
 */

/*
 * Link styles
 * https://github.com/WordPress/gutenberg/issues/42319
 */
html {
  scroll-behavior: smooth;
}
a {
  text-decoration-thickness: 1px !important;
  text-underline-offset: 0.1em;
}

/* Focus styles */
:where(.wp-site-blocks *:focus) {
  outline-width: 2px;
  outline-style: solid;
  color: #131823;
}

/* Increase the bottom margin on submenus, so that the outline is visible. */
.wp-block-navigation
  .wp-block-navigation-submenu
  .wp-block-navigation-item:not(:last-child) {
  margin-bottom: 3px;
}

/* Increase the outline offset on the parent menu items, so that the outline does not touch the text. */
.wp-block-navigation
  .wp-block-navigation-item
  .wp-block-navigation-item__content {
  outline-offset: 4px;
}

/* Remove outline offset from the submenus, otherwise the outline is visible outside the submenu container. */
.wp-block-navigation
  .wp-block-navigation-item
  ul.wp-block-navigation__submenu-container
  .wp-block-navigation-item__content {
  outline-offset: 0;
}

/*
 * Progressive enhancement to reduce widows and orphans
 * https://github.com/WordPress/gutenberg/issues/55190
 */
h1,
h2,
h3,
h4,
h5,
h6,
blockquote,
caption,
figcaption,
p {
  text-wrap: pretty;
}

/*
 * Change the position of the more block on the front, by making it a block level element.
 * https://github.com/WordPress/gutenberg/issues/65934
*/
.more-link {
  display: block;
}
.height-100 svg {
  height: 15rem;
  width: auto;
}
svg {
  max-width: 100%;
  height: auto;
}
.height-4em {
  height: 4em;
  width: auto;
}
header svg {
  width: 2em;
  height: auto;
  margin: 0.75em 0.75em 0.5em 0.25em;
}
.has-contrast-background-color svg:hover #drone .st0 {
  fill: var(--wp--preset--color--white);
  animation: spin 0.5s infinite ease-in-out !important  ;
}
.has-contrast-background-color #drone .st0 {
  fill: var(--wp--preset--color--white);
  animation: spin 25.02s infinite ease-in-out !important  ;
}
.has-contrast-background-color .st1 {
  fill: var(--wp--preset--color--white);
  stroke: var(--wp--preset--color--white);
  stroke-miterlimit: 10;
  stroke-width: 7.7px;
}
.has-contrast-background-color .st2 {
  fill: var(--wp--preset--color--white);
}

#drone .st0 {
  fill: var(--wp--preset--color--contrast);
}
.animate #drone .st0 {
  /* Viktigt för SVG: rotera kring pathens egen "låda" */
  transform-box: fill-box;
  transform-origin: center;
}
.animate:hover #drone .st0 {
  /* Viktigt för SVG: rotera kring pathens egen "låda" */
  transform-box: fill-box;
  transform-origin: center;
  animation: spin 0.2s linear 2 !important;
}
.st1 {
  fill: var(--wp--preset--color--contrast);
  stroke: var(--wp--preset--color--contrast);
  stroke-miterlimit: 10;
  stroke-width: 7.7px;
}
.st2 {
  fill: var(--wp--preset--color--contrast);
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
} /* Tillgänglighet: stoppa animation för användare som föredrar mindre rörelse */
@media (prefers-reduced-motion: reduce) {
  .st0 {
    animation: none;
  }
}

.is-style-section-1 .wp-block-font-awesome-icon svg,
.is-style-section-2 .wp-block-font-awesome-icon svg {
  color: var(--wp--preset--color--accent);
}
/* Grid layout för formuläret */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.form-grid .full {
  grid-column: 1 / -1;
}

/* Inputs */
.form-grid input[type="text"],
.form-grid input[type="email"],
.form-grid textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--wp--preset--color--neutral-light);
  border-radius: 0.4em;
  font-family: inherit;
  font-size: 1rem;
  background: #fff;
  transition: border-color 0.2s ease;
  box-sizing: border-box;
}

.form-grid input:focus,
.form-grid textarea:focus {
  border-color: var(--wp--preset--color--accent);
  outline: none;
}

/* Textarea */
.form-grid textarea {
  min-height: 160px;
  resize: vertical;
}

/* Submit-knapp */
.form-grid .submit input[type="submit"] {
  background: var(--wp--preset--color--accent);
  color: var(--wp--preset--color--base);
  border: none;
  padding: 1rem 2.5rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2rem;
  border-radius: 0.4em;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.form-grid .submit input[type="submit"]:hover {
  background: var(--wp--preset--color--neutral-dark);
  color: var(--wp--preset--color--base);
}

/* Mobilanpassning */
@media (max-width: 768px) {
  .form-grid {
    grid-template-columns: 1fr;
  }
}