/*
Theme Name: Studierendenwerk Paderborn 2025
Theme URI: 
Author: GUTWERKER
Author URI: 
Description: Ein WordPress Blocktheme für das Studierendenwerk Paderborn aus dem Jahr 2025
Requires at least: 6.8
Tested up to: 6.8
Requires PHP: 7.2
Version: 1.1.3
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: studierendenwerk-paderborn-2025
Tags: one-column, custom-colors, custom-menu, custom-logo, editor-style, featured-images, full-site-editing, block-patterns, rtl-language-support, sticky-post, threaded-comments, translation-ready, wide-blocks, block-styles, style-variations, accessibility-ready, blog, portfolio, news

/* basic stylings */

/* Styles intended only for the frontend.*/
html {
  scroll-behavior: smooth;
  line-height: 1.15;
  /* 1 */
  -webkit-text-size-adjust: 100%;
  /* 2 */
  overflow-x: clip;

  scrollbar-gutter: stable;
  scrollbar-color: var(--wp--preset--color--contrast) var(--wp--preset--color--base);
  scrollbar-width: .5rem;

  text-underline-offset: .25rem;
  text-decoration-thickness: 2px;
}

/* 1. Use a more-intuitive box-sizing model */
*,
*::before,
*::after {
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
}

/* 3. Enable keyword animations */
@media (prefers-reduced-motion: no-preference) {
  html {
    interpolate-size: allow-keywords;
  }
}

body {
  /* 5. Improve text rendering */
  -webkit-font-smoothing: antialiased;
}

/* 6. Improve media defaults */
img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}

/* 7. Inherit fonts for form controls */
input,
button,
textarea,
select {
  font: inherit;
}

/* 8. Avoid text overflows */
p,
h1,
h2,
h3,
h4,
h5,
h6,
a {
  overflow-wrap: break-word;
}

/* 9. Improve line wrapping */
p {
  text-wrap: pretty;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  text-wrap: balance;
}

/*
    10. Create a root stacking context
  */
#root,
#__next {
  isolation: isolate;
}

/* Abstand des Contents zur Nav-Bar abhängig von der Nav-Bar-Höhre */
.content-margin-top {
  margin-top: var(--wp--custom--header-height) !important;
}

@media screen and (prefers-reduced-motion: reduce) {

  html {
    scroll-behavior: auto;
  }
}

body {
  -moz-osx-font-smoothing: grayscale;
  -webkit-font-smoothing: antialiased;
  margin: 0;
  overflow-x: clip;
  max-width: 100%;
}


* {
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
}

a {
  -webkit-transition: all 0.3s ease;
  -o-transition: all 0.3s ease;
  transition: all 0.3s ease;

  &.wp-block-tiptip-hyperlink-group-block {
    text-decoration: none;
  }
}


/* 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;
}


/*
 * 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;
}

/* Hover-Effekt Navi-Links 
nav a:hover {
	color: var(--wp--preset--color--accent-1) !important;
}

header nav a::after,
footer nav a::after {
    content: '';
    position: absolute;
    bottom: 0; 
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--wp--preset--color--accent-1);
    -webkit-transition: width 0.3s ease;
    -o-transition: width 0.3s ease;
    transition: width 0.3s ease;
}

header nav a:hover::after,
footer nav a:hover::after {
    width: 100%;
}
*/

.ff_btn_style:hover,
.ff_btn_style:focus {
  background-color: var(--wp--preset--color--accent-2) !important;
  opacity: 1 !important;
  border-color: var(--wp--preset--color--accent-2) !important;
  color: var(--wp--preset--color--base) !important;
}

header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 9999;
  -webkit-transition: top 0.6s ease-in-out;
  -o-transition: top 0.6s ease-in-out;
  transition: top 0.6s ease-in-out;
  /* Sanfte Bewegung */
}

body.admin-bar header {
  top: 32px;
}

/*
Theme Name: Studierendenwerk Paderborn 2025
Theme URI: 
Author: GUTWERKER
Author URI: 
Description: Ein WordPress Blocktheme für das Studierendenwerk Paderborn aus dem Jahr 2025
Requires at least: 6.8
Tested up to: 6.8
Requires PHP: 7.2
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: studierendenwerk-paderborn-2025
Tags: one-column, custom-colors, custom-menu, custom-logo, editor-style, featured-images, full-site-editing, block-patterns, rtl-language-support, sticky-post, threaded-comments, translation-ready, wide-blocks, block-styles, style-variations, accessibility-ready, blog, portfolio, news

/* basic stylings */

/* Styles intended only for the frontend.*/
html {
  scroll-behavior: smooth;
  line-height: 1.15;
  /* 1 */
  -webkit-text-size-adjust: 100%;
  /* 2 */
  overflow-x: clip;

  scrollbar-gutter: stable;
  scrollbar-color: var(--wp--preset--color--contrast) var(--wp--preset--color--base);
  scrollbar-width: .5rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* 1. Use a more-intuitive box-sizing model */
*,
*::before,
*::after {
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
}

/* 3. Enable keyword animations */
@media (prefers-reduced-motion: no-preference) {
  html {
    interpolate-size: allow-keywords;
  }
}

body {
  /* 5. Improve text rendering */
  -webkit-font-smoothing: antialiased;
}

/* 6. Improve media defaults */
img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}

/* 7. Inherit fonts for form controls */
input,
button,
textarea,
select {
  font: inherit;
}

/* 8. Avoid text overflows */
p,
h1,
h2,
h3,
h4,
h5,
h6,
a {
  -webkit-hyphens: auto;
  -ms-hyphens: auto;
  hyphens: auto;

  hyphenate-limit-chars: 12 auto 4;
}

/* 9. Improve line wrapping */
p {
  text-wrap: pretty;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  text-wrap: balance;
}


/*
    10. Create a root stacking context
  */
#root,
#__next {
  isolation: isolate;
}

/* Abstand des Contents zur Nav-Bar abhängig von der Nav-Bar-Höhre */
.content-margin-top {
  margin-top: var(--wp--custom--header-height) !important;
}

@media screen and (prefers-reduced-motion: reduce) {

  html {
    scroll-behavior: auto;
  }
}

body {
  -moz-osx-font-smoothing: grayscale;
  -webkit-font-smoothing: antialiased;
  margin: 0;
  overflow-x: clip;
  max-width: 100%;
}


* {
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
}

a {
  -webkit-transition: all 0.3s ease;
  -o-transition: all 0.3s ease;
  transition: all 0.3s ease;
}


/* 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;
}


/*
 * 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;
}

/* Hover-Effekt Navi-Links 
nav a:hover {
	color: var(--wp--preset--color--accent-1) !important;
}

header nav a::after,
footer nav a::after {
    content: '';
    position: absolute;
    bottom: 0; 
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--wp--preset--color--accent-1);
    -webkit-transition: width 0.3s ease;
    -o-transition: width 0.3s ease;
    transition: width 0.3s ease;
}

header nav a:hover::after,
footer nav a:hover::after {
    width: 100%;
}
*/

.ff_btn_style:hover,
.ff_btn_style:focus {
  background-color: var(--wp--preset--color--accent-2) !important;
  opacity: 1 !important;
  border-color: var(--wp--preset--color--accent-2) !important;
  color: var(--wp--preset--color--base) !important;
}


/* Dynamic Post Titles */
.gspb-dynamic-post-title .gspb-dynamic-title-element {
  margin: 0 !important;
}

body>.wp-site-blocks {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -ms-flex-direction: column;
  flex-direction: column;
  min-height: 100vh;

  main {
    -webkit-box-flex: 1;
    -ms-flex: 1;
    flex: 1;
  }
}

.wp-block-search__label {
  background: var(--wp--preset--color--contrast);
  color: var(--wp--preset--color--base);
  padding: .2rem .4rem;
  font-size: var(--wp--preset--font-size--small);
  border-radius: 6px 6px 0 0;
  margin-left: 1rem;
  display: block;
  width: fit-content;
}


/* color the blogposts in each categorie */
ul.wp-block-post-template>li.gspbgrid_item {

  /* befoeg */
  &:has(.post-categories .term-66) {
    --wp--preset--color--accent-1: var(--wp--preset--color--contrast, #000);
  }

  /* beratung */
  &:has(.post-categories .term-138) {
    --wp--preset--color--accent-1: var(--wp--preset--color--accent-4, #d14d72);
    --wp--preset--color--base: var(--wp--preset--color--contrast, #000);
  }

  /* wohnen */
  &:has(.post-categories .term-139) {
    --wp--preset--color--accent-1: var(--wp--preset--color--accent-2, #00989a);
  }

  /* gastronomie */
  &:has(.post-categories .term-140) {
    --wp--preset--color--accent-1: var(--wp--preset--color--accent-3, #c2da36);
    --wp--preset--color--base: var(--wp--preset--color--contrast, #000);
  }
}


body {

  .fls_login_wrapper #fls_magic_submit,
  .fls_login_wrapper input#wp-submit {
    background: var(--wp--preset--color--accent-1);
    color: var(--wp--preset--color--base);
  }

}