/*
 Theme Name:   meineAkademie
 Theme URI:    https://reiseland-holding.de
 Description:  Default GeneratePress child theme for the E-Learning-Platform meineAkademie
 Author:       Enrico Lauterschlag
 Author URI:   https://tomusborne.com
 Template:     generatepress
 Version:      0.1
*/

a{
	text-decoration: none;
}

.sfwd-courses-template-default .site-content,
.sfwd-lessons-template-default .site-content,
.sfwd-topic-template-default .site-content,
.sfwd-quiz-template-default .site-content,
.post-template-default .site-content,
.page-id-1966 .site-content {
	margin: 60px 0 80px;
}

.wp-block-embed,
.wp-block-gallery,
.wp-block-image,
.wp-block-video {
	margin-bottom:40px;
}

.login-button {
	background-color: #00758f;
	border-radius:10px;
	margin-left:15px;
}

.login-button a {
	color:#fff !important;
}

.login-button:hover {
	background-color: #0093b6;
}

.site-logo.mobile-header-logo img {
  height: 80px !important;
  width: auto;
}

/* Ultimate Member */

.um-account.um-editing .um-account-meta,
.um-account.um-editing .um-profile-meta{
	display:none;
}

.um-account.um-editing .um-account-main a.um-profile-photo-img {
  top: 0 !important;
}

.um input[type="submit"].um-button {
  background-color: #00758f !important;
}

.um input[type="submit"].um-button:hover {
  background-color: #0093b6 !important;
}

.um:not(.um-admin) {
    color: #000 !important;
    font-size: 20px !important;
}

/* LEARNDASH */

.ld-button{
	border: 2px solid #00758f;
}

.ld-button:hover{
	background-color: #f0f0f0;
}

.learndash-wrapper:not(.ld-registration__outer-wrapper):not(.learndash-wrapper--modern) .learndash-shortcode-wrap {
	margin-bottom:40px;
}

.learndash-wrapper:not(.ld-registration__outer-wrapper):not(.learndash-wrapper--modern) .ld-content-actions {
  margin-top: 60px;
}

.learndash-wrapper .ld-course-status,
.learndash-wrapper .ld-lesson-status,
.learndash-wrapper .ld-topic-status,
.learndash-wrapper .ld-breadcrumbs {
  background-color: rgba(0, 117, 143, 0.05) !important;
  border-radius: 20px !important;
}

.learndash-wrapper .wpProQuiz_content .wpProQuiz_question_text {
  font-weight: 700 !important;
}

.learndash-wrapper .wpProQuiz_content .wpProQuiz_questionListItem:not(.ld-sortable__item) label.is-selected, .learndash-wrapper .wpProQuiz_content .wpProQuiz_questionListItem:not(.ld-sortable__item) label:focus-within {
  border-color: var(--accent) !important;
}

.learndash-wrapper .wpProQuiz_content .wpProQuiz_questionList input.wpProQuiz_questionInput {
  accent-color: var(--accent);
}

.course-partner-logo {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 10;
	background-color: var(--base-3);
}

.course-partner-logo-round {
    position: absolute;
    bottom: 60px;
    left: 50%;
	transform: translatex(-50%);
    z-index: 10;
	background-color: var(--base-3);
}

.course-partner-logo img,
.course-partner-logo-round img{
	width:auto;
	max-width:160px;
	height:50px;
	object-fit:contain;
}

/* LEARNDASH HIDE ELEMENTS */

body.sfwd-courses-template-default
  :is([class^="learndash-shortcode-wrap-ld_infobar"],
      [class*="learndash-shortcode-wrap-ld_infobar"]) {
  display:none;
}

body.sfwd-courses-template-default
  :is([class^="learndash-shortcode-wrap-course_content"],
      [class*="learndash-shortcode-wrap-course_content"]) {
  display:none;
}

body.sfwd-courses-template-default
  :is([class^="learndash-shortcode-wrap-ld_certificate"],
      [class*="learndash-shortcode-wrap-ld_certificate"]) {
  display:none;
}

.learndash-wrapper:not(.ld-registration__outer-wrapper):not(.learndash-wrapper--modern) .learndash_mark_complete_button {
	display:none !important;
}

.ld-profile__saved-cards {
	display:none;
}

.learndash-wrapper .ld-table-list .ld-table-list-header .ld-table-list-columns .ld-column-certificate,
.learndash-wrapper .ld-table-list .ld-table-list-item-preview .ld-table-list-columns .ld-table-list-column-certificate {
  display:none;
}


/* LEARNDASH INFOBAR */

/* LearnDash Kurs-Grid Shortcode */
.rl-course-infobar {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
	align-items: stretch;
    margin-bottom: 40px;
	padding: 1em 0;
	background-color: rgba(0, 117, 143, 0.05);
	border-radius:20px;
}

.rl-course-infobar .rl-col {
    padding: 0 1em;
	border-right: 2px solid var(--accent);
	text-align:center;
}

.rl-course-infobar .rl-col:last-child {
	border-right: 0;
}

.rl-course-infobar .rl-status {
    font-weight: bold;
}

.rl-course-infobar .rl-status-text{
	margin-bottom:0;
	background-color: #ffd200;
	display:inline-block;
	width:auto;
	max-width:100%;
	padding: 5px 12px;
	font-size:11px;
	text-transform: uppercase;
	border-radius:10px;
}

.rl-course-infobar .rl-course-infobar-title{
  	font-size: .75em;
  	font-weight: 700;
  	margin-bottom: 1em;
}
.rl-course-infobar .rl-course-infobar-price {
	font-size: 32px;
	font-weight: 700;
	margin-bottom:0;
}

.rl-course-infobar .learndash-shortcode-wrap {
	margin-bottom:0 !important;
}

.rl-course-infobar .btn-join,
.rl-course-infobar .ld-button{
    display: inline-block !important;
	margin-bottom:10px !important;
    width: auto !important;             /* verhindert 100%-Breite */
    max-width: 100% !important;
	font-weight:700 !important;
	color:#fff !important;
	background-color: var(--accent) !important;
}


.rl-course-infobar .btn-join:hover,
.rl-course-infobar .ld-button:hover {
    background-color: rgba(0, 117, 143, 0.8) !important;
}

/* LEARNDASH LESSON LIST */

/* Wrapper für die Lessons */
.rl-course-lessons-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center; /* sorgt dafür, dass 1 Item mittig steht */
    gap: 40px; /* Abstand zwischen den Boxen */
    margin: 40px 0 60px;
}

/* Jede Lesson-Box */
.rl-lesson-item {
    flex: 1 1 calc(50% - 20px); /* maximal zwei pro Zeile */
	max-width: calc(50% - 20px);
    box-sizing: border-box;
    text-align: center;
	position: relative;
	border-radius:20px;
	border:3px solid var(--accent);
}

/* Thumbnail */
.rl-lesson-item img.lesson-thumb {
    max-width: 100%;
    height: 280px;
	object-fit: cover;
	display:block;
	border-radius:20px 20px 0 0;
}

.rl-lesson-item .rl-lesson-item-thumbnail{
	position:relative;
}

.rl-lesson-item-thumbnail > .gb-shapes .gb-shape-1 {
  color: var(--base-3);
  position: absolute;
  overflow: hidden;
  pointer-events: none;
  line-height: 0;
  left: 0;
  right: 0;
  bottom: -1px;
}

.rl-lesson-item-thumbnail > .gb-shapes .gb-shape-1 svg {
  height: 20px;
  width: calc(100% + 1.3px);
  fill: currentColor;
  position: relative;
  left: 50%;
  transform: translateX(-50%);
  min-width: 100%;
}

.rl-lesson-item-thumbnail > .gb-shapes .gb-shape-2 {
  color: rgba(255, 255, 255, 0.5);
  position: absolute;
  overflow: hidden;
  pointer-events: none;
  line-height: 0;
  left: 0;
  right: 0;
  bottom: -1px;
}

.rl-lesson-item-thumbnail > .gb-shapes .gb-shape-2 svg {
  height: 125px;
  width: 175%;
  fill: currentColor;
  position: relative;
  left: 50%;
  transform: translateX(-50%);
  min-width: 100%;
}

/* Titel */
.rl-lesson-title {
    font-size: 1.3em;
	padding: 40px 20px;
	margin:0;
}

/* Overlay-Tooltip */
.rl-lesson-item.not-enrolled::after {
    content: "Sie müssen zuerst den Kurs belegen, bevor Sie die Inhalte des Kapitels aufrufen können.";
    position: absolute;
    inset: 0; /* oben, rechts, unten, links = 0 → füllt kompletten Container */
    background: rgba(0, 0, 0, 0.65); /* halbtransparentes Schwarz */
    color: #fff;
	border-radius:20px;
    display: flex; /* für zentrierten Text */
    align-items: center;
    justify-content: center;
    padding: 20px;
    text-align: center;
    opacity: 0;
    pointer-events: none; /* damit Klicks nicht blockiert werden */
    transition: opacity 0.25s ease;
    z-index: 5;
}

/* Sichtbar beim Hover */
.rl-lesson-item.not-enrolled:hover::after {
    opacity: 1;
    pointer-events: auto; /* wenn du möchtest, dass der User interagieren kann */
}

@media (max-width: 768px) {
	.sfwd-courses-template-default .site-content,
	.sfwd-lessons-template-default .site-content,
	.sfwd-topic-template-default .site-content,
	.sfwd-quiz-template-default .site-content,
	.post-template-default .site-content,
	.page-id-1966 .site-content {
		margin: 40px 0 60px;
	}
	.rl-course-infobar {
        grid-template-columns: 1fr; /* nur noch 1 Spalte */
		padding:0 40px;
    }

    .rl-course-infobar .rl-col {
        border-right: none;        /* rechte Linie weg */
        border-bottom: 2px solid var(--accent); /* stattdessen unten eine Linie */
		padding: 40px 0;
    }

    .rl-course-infobar .rl-col:last-child {
        border-bottom: none; /* unterste Box ohne Linie */
    }
	.rl-course-lessons-grid {
		margin: 40px 0;
	}
	.rl-lesson-item {
		flex: 1 1 100%;
		max-width: 100%;
	}
}

@media (max-width: 640px) {
    .learndash-wrapper #ld-profile .ld-section-heading .ld-expand-button {
        max-width: 180px !important;
    }
	.learndash-wrapper .ld-item-list .ld-item-list-item .ld-item-list-item-preview .ld-item-details {
        width: 100%;
        box-sizing: border-box;
    }
	.learndash-wrapper .ld-item-list .ld-item-list-item .ld-item-list-item-preview .ld-item-details {
        margin-top: 10px !important;
    }
}
