/*
Theme Name: Purple Modena Child
Theme URI: https://maalarimestariliiti.fi
Description: Child theme for purple-modena. All custom CSS lives here so that
             nothing has to be edited in the parent theme (dated 2016), which a
             theme update would overwrite.
Author: Maalarimestari Liiti
Template: purple-modena
Version: 0.1
*/

/* ------------------------------------------------------------------------
   1. Cuprum, served from this site instead of fonts.googleapis.com
   The files already sit in the parent theme; the parent only used them as an
   Internet Explorer fallback and fetched the real font from Google. These
   rules define the plain family name "Cuprum" that the parent's CSS asks for,
   so nothing else has to change and no visitor's address goes to Google.
   ------------------------------------------------------------------------ */
@font-face{
	font-family: 'Cuprum';
	src: url('../purple-modena/fonts/cuprum-regular-webfont.woff') format('woff'),
	     url('../purple-modena/fonts/cuprum-regular-webfont.ttf') format('truetype');
	font-weight: 400; font-style: normal; font-display: swap;
}
@font-face{
	font-family: 'Cuprum';
	src: url('../purple-modena/fonts/cuprum-italic-webfont.woff') format('woff'),
	     url('../purple-modena/fonts/cuprum-italic-webfont.ttf') format('truetype');
	font-weight: 400; font-style: italic; font-display: swap;
}
@font-face{
	font-family: 'Cuprum';
	src: url('../purple-modena/fonts/cuprum-bold-webfont.woff') format('woff'),
	     url('../purple-modena/fonts/cuprum-bold-webfont.ttf') format('truetype');
	font-weight: 700; font-style: normal; font-display: swap;
}
@font-face{
	font-family: 'Cuprum';
	src: url('../purple-modena/fonts/cuprum-bolditalic-webfont.woff') format('woff'),
	     url('../purple-modena/fonts/cuprum-bolditalic-webfont.ttf') format('truetype');
	font-weight: 700; font-style: italic; font-display: swap;
}

/* ------------------------------------------------------------------------
   2. The Ennustaja Pro menu item.
   Three looks. Switch by putting v1, v2 or v3 in
   wp-content/themes/purple-modena-child/variant.txt and reloading.
   The font, size and capitals are the parent's in all three: only the
   decoration differs, because Cuprum has no cut heavier than the 700 the
   menu already uses.
   ------------------------------------------------------------------------ */

/* --- v1: filled pill ---------------------------------------------------- */
body.ep-v1 nav.menu li.menu-ennustaja > a{
	margin: 18px 14px;
	padding: 12px 22px;
	background: #fff;
	color: #406;
	border-radius: 999px;
	text-shadow: none;
	box-shadow: 0 0 6px rgba(64,0,102,.35);
}
body.ep-v1 nav.menu li.menu-ennustaja:hover > a{
	background: #406;
	color: #fff;
}

/* --- v2: looks identical, pulses three times when the page opens --------- */
body.ep-v2 nav.menu li.menu-ennustaja > a{
	animation: ep-pulse 1.5s ease-in-out 3;
}
@keyframes ep-pulse{
	0%   { text-shadow: 0 0 5px #aba3c3; }
	50%  { text-shadow: 0 0 4px #fff, 0 0 12px #fff, 0 0 22px #d9b3ff; }
	100% { text-shadow: 0 0 5px #aba3c3; }
}

/* --- v3: looks identical, breathes very slowly, never stops -------------- */
body.ep-v3 nav.menu li.menu-ennustaja > a{
	animation: ep-breathe 4.5s ease-in-out infinite;
}
@keyframes ep-breathe{
	0%,100% { text-shadow: 0 0 5px #aba3c3; }
	50%     { text-shadow: 0 0 5px #fff, 0 0 14px #cfa8ff; }
}

/* Anyone who has asked their device to reduce motion gets no animation.
   Required for accessibility, and it costs nothing. */
@media (prefers-reduced-motion: reduce){
	body.ep-v2 nav.menu li.menu-ennustaja > a,
	body.ep-v3 nav.menu li.menu-ennustaja > a{
		animation: none;
		text-shadow: 0 0 5px #fff, 0 0 12px #cfa8ff;
	}
}

/* === Ennustaja Pro page === */

/* --- a second, English line under a menu item ---------------------------- *
   The parent gives every link 30px of padding top and bottom. A second line
   would make that item taller than the rest and drag the bar out of shape, so
   its padding is reduced by the height the second line adds and all items are
   centred against each other. Measured at 1500, 1280, 1100, 820 and 390 px:
   the bar stays the same height as before at every one.                      */
nav.menu li{ vertical-align: middle; }
nav.menu li.menu-two-line > a{
	padding-top: 21px;
	padding-bottom: 21px;
	line-height: 1.15;
}
nav.menu li.menu-two-line .menu-sub{
	display: block;
	margin-top: 2px;
	font-size: 1.2rem;
	font-weight: normal;
	text-transform: none;
	letter-spacing: .02em;
	opacity: .92;
}

/* The theme prints the page title as a linked h2. On this page the heading is
   part of the block below instead, so the theme's own one is hidden here. */
body.ep-page .entry-title{ display: none; }

.ep-wrap{ margin: 0 0 10px; }
.ep-head{
	display: flex; align-items: baseline; justify-content: space-between;
	flex-wrap: wrap; gap: 10px 24px;
	padding-bottom: 12px; margin-bottom: 24px;
	border-bottom: 1px solid #d8d2e4;
}

/* Both names are always shown. Whichever language is selected takes the large
   black treatment and comes first; the other follows, small and grey, after a
   slash. Confirmed by Janne 2026-11-02: an English speaker then sees at once
   that he is on the right page. */
.ep-name{
	display: flex; align-items: baseline; flex-wrap: wrap; gap: 0 10px;
	margin: 0; line-height: 1.1;
	font-family: Cuprum, 'Trebuchet MS', Tahoma, sans-serif;
}
.ep-name span{ transition: color .18s ease, font-size .18s ease; }
.ep-wrap.lang-fi .ep-n-fi{ order: 1; color: #000; font-weight: 700; font-size: 3.2rem; }
.ep-wrap.lang-fi .ep-n-en{ order: 2; color: #7a6f85; font-weight: 400; font-size: 2rem; white-space: nowrap; }
.ep-wrap.lang-fi .ep-n-en::before{ content: "/ "; }
.ep-wrap.lang-en .ep-n-en{ order: 1; color: #000; font-weight: 700; font-size: 3.2rem; }
.ep-wrap.lang-en .ep-n-fi{ order: 2; color: #7a6f85; font-weight: 400; font-size: 2rem; white-space: nowrap; }
.ep-wrap.lang-en .ep-n-fi::before{ content: "/ "; }

.ep-lang{ display: flex; align-items: center; gap: 6px; }
.ep-lang-sep{ color: #aba3c3; font-size: 1.8rem; }
.ep-lang-btn{
	margin: 0; padding: 6px 14px;
	border: 1px solid #aba3c3; border-radius: 999px;
	background: transparent; color: #406;
	font: bold 1.6rem Cuprum, 'Trebuchet MS', Tahoma, sans-serif;
	text-transform: uppercase; cursor: pointer;
	transition: background-color .15s ease, color .15s ease;
}
.ep-lang-btn:hover{ background: #eae8f0; }
.ep-lang-btn.is-on{ background: #406; border-color: #406; color: #fff; }
.ep-lang-btn:focus-visible{ outline: 3px solid #aba3c3; outline-offset: 2px; }

.ep-wrap .t-en{ display: none; }
.ep-wrap.lang-en .t-fi{ display: none; }
.ep-wrap.lang-en .t-en{ display: inline; }

.ep-lead{ font-size: 1.8rem; line-height: 1.5; }

.ep-box{
	max-width: 420px; margin: 28px 0 10px; padding: 22px 24px 18px;
	background: #f6f4fa; border: 1px solid #d8d2e4; border-radius: 6px;
}
.ep-box-title{ margin: 0 0 6px; color: #406; font: bold 2.2rem Cuprum, 'Trebuchet MS', Tahoma, sans-serif; }
.ep-note{ margin: 0 0 16px; color: #7a6f85; font-size: 1.4rem; }
.ep-field{ margin-bottom: 12px; }
.ep-field label{ display: block; margin-bottom: 4px; font-size: 1.5rem; color: #4a4152; }
.ep-field input{ width: 100%; padding: 9px 10px; border: 1px solid #c8c0d6; border-radius: 4px; background: #fff; font-size: 1.6rem; }
.ep-actions{ display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 0; }
.ep-btn{
	display: inline-block; padding: 11px 20px; border-radius: 999px;
	background: #fff; border: 1px solid #406; color: #406;
	font: bold 1.6rem Cuprum, 'Trebuchet MS', Tahoma, sans-serif; text-transform: uppercase;
}
.ep-btn-main{ background: #406; color: #fff; }

@media (max-width: 640px){
	.ep-wrap.lang-fi .ep-n-fi, .ep-wrap.lang-en .ep-n-en{ font-size: 2.6rem; }
	.ep-wrap.lang-fi .ep-n-en, .ep-wrap.lang-en .ep-n-fi{ font-size: 1.7rem; white-space: normal; }
	.ep-head{ flex-direction: column; align-items: flex-start; }
}

/* --- the English sub-line, everywhere it appears ------------------------- *
   Found 2026-11-03: the footer PIKAMENU widget printed "YhteydenottoContact
   details" as one word. The sub-line span is added by the nav_menu_item_title
   filter, which runs for EVERY menu, but the rule that puts it on its own line
   was scoped to nav.menu - the top bar only. Anywhere else it stayed inline.

   This is a base rule on the class alone, so its specificity (0,1,0) is far
   below the top bar's nav.menu li.menu-two-line .menu-sub (0,3,2). The bar's
   measured padding and sizing are therefore untouched; this only catches the
   footer menu and any other place the same menu is output.                   */
.menu-sub{
	display: block;
	font-size: .82em;
	font-weight: normal;
	text-transform: none;
	letter-spacing: .02em;
	opacity: .9;
}

/* --- W51 (Janne, 2026-11-04): one name in both languages ---------------- *
   The product is Ennustaja Pro in Finnish AND English. English gets a tagline
   instead of a translated name:

       FI   Rakastu kotiisi uudelleen
       EN   Fall in love with your home again

   His reason, and it is better than either of Claude's: the whole point of the
   tool is that the customer SEES IT HIMSELF, on his own wall, instead of taking
   a salesperson's word for it. The tagline promises exactly that outcome, and
   it is his home, not our suggestion.

   This supersedes decision 42 (Ennustaja Pro / Clairvoyant Pro) and the part of
   decision 44 about showing both names at once. The heading no longer signals
   that English exists, so the TAGLINE now carries that job: pressing FIN/ENG
   visibly changes the line under the name. That was Janne's own observation.

   The .ep-n-fi / .ep-n-en rules above are left in place deliberately. They match
   nothing now, cost nothing, and removing them is a separate tidy-up that should
   not ride along with a live content change.                                 */
.ep-titles{
	display: flex;
	flex-direction: column;
	gap: 3px;
	min-width: 0;
}
.ep-name{
	font-size: 3.2rem;
	font-weight: 700;
	color: #000;
	margin: 0;
	line-height: 1.05;
}
.ep-tagline{
	margin: 0;
	font-size: 1.9rem;
	line-height: 1.25;
	color: #7a6f85;
	font-weight: 400;
}

@media (max-width: 600px) {
	.ep-name{ font-size: 2.6rem; }
	.ep-tagline{ font-size: 1.6rem; }
}
