/*
Theme Name: tolove Proposal Artisan
Theme URI: https://tolove.tw/
Author: ERP_NAS
Author URI: https://tolove.tw/
Description: 求婚職人 tolove 官網主題 — 求婚企劃・求婚微電影・求婚佈置。忠實還原設計稿的自訂主題，相容 WooCommerce。Faithful reproduction of the tolove static design mockup. Editorial serif layout (Instrument Serif + Noto Serif TC), scroll-driven reveal animations, hero slider, film-player modal.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
Text Domain: tolove
Tags: custom, one-page, editorial, woocommerce
*/

/* ============================================================
   Base — ported from the mockup's inline <style> block.
   Palette: paper #edeae3 / ink #1f1d1a / clay #a8785f
   ============================================================ */
:root{
  --paper:#edeae3; --ink:#1f1d1a; --clay:#a8785f;
  --line:#d6d1c5; --line2:#c9c3b5; --muted:#8a8377; --body:#57524a;
  --dark:#191715; --darkfg:#edeae3;
}
*{box-sizing:border-box;}
html{-webkit-text-size-adjust:100%;}
body{
  margin:0;
  background:var(--paper);
  color:var(--ink);
  font-family:'Jost','Noto Sans TC',sans-serif;
  overflow-x:hidden;
  position:relative;
}
a{color:var(--ink); text-decoration:none;}
a:hover{color:var(--clay);}
img{max-width:100%; display:block;}
::selection{background:#ded8cb; color:var(--ink);}
h1,h2,h3{font-weight:400;}

/* keyframes */
@keyframes tl-marquee{from{transform:translateX(0)}to{transform:translateX(-50%)}}
@keyframes tl-rise{from{opacity:0; transform:translateY(18px)}to{opacity:1; transform:translateY(0)}}
@keyframes tl-in{from{opacity:0; transform:translateY(30px)}to{opacity:1; transform:none}}
@keyframes tl-wipe{from{clip-path:inset(0 0 100% 0)}to{clip-path:inset(0 0 0 0)}}
@keyframes tl-drift{from{transform:translateY(-6%) scale(1.12)}to{transform:translateY(6%) scale(1.12)}}
@keyframes tl-mask{from{clip-path:inset(0 0 102% 0); transform:scale(1.06)}to{clip-path:inset(0 0 0 0); transform:scale(1)}}
@keyframes tl-slide-up{from{opacity:0; transform:translateY(46px)}to{opacity:1; transform:none}}
@keyframes tl-fade{from{opacity:0}to{opacity:1}}
@keyframes tl-rule{from{transform:scaleX(0)}to{transform:scaleX(1)}}
@keyframes tl-pull{from{transform:translateY(38px)}to{transform:translateY(-38px)}}

/* scroll-driven reveals (modern browsers) */
[data-reveal]{animation:tl-in linear both; animation-timeline:view(); animation-range:entry 4% cover 24%;}
[data-drift]{animation:tl-drift linear both; animation-timeline:view(); animation-range:cover 0% cover 100%;}
[data-mask]{animation:tl-mask linear both; animation-timeline:view(); animation-range:entry 2% cover 22%;}
[data-line]{animation:tl-slide-up linear both; animation-timeline:view(); animation-range:entry 6% cover 26%;}
[data-line="2"]{animation-range:entry 2% cover 28%;}
[data-line="3"]{animation-range:entry 0% cover 30%;}
[data-rule]{transform-origin:left center; animation:tl-rule linear both; animation-timeline:view(); animation-range:entry 10% cover 24%;}
[data-late]{animation:tl-fade linear both; animation-timeline:view(); animation-range:entry 14% cover 30%;}
[data-pull]{animation:tl-pull linear both; animation-timeline:view(); animation-range:cover 0% cover 100%;}

/* JS/IntersectionObserver fallback for browsers without animation-timeline */
@supports not (animation-timeline: view()){
  [data-reveal],[data-mask],[data-line],[data-rule],[data-late]{animation:none; opacity:0}
  [data-mask]{opacity:1; clip-path:inset(0 0 102% 0)}
  [data-rule]{opacity:1; transform:scaleX(0)}
  [data-drift],[data-pull]{animation:none; transform:none}
  [data-reveal][data-inview]{animation:tl-in 0.9s cubic-bezier(.16,1,.3,1) both}
  [data-mask][data-inview]{animation:tl-mask 1.05s cubic-bezier(.16,1,.3,1) both}
  [data-late][data-inview]{animation:tl-fade 0.9s ease 0.25s both}
  [data-rule][data-inview]{animation:tl-rule 0.8s cubic-bezier(.16,1,.3,1) both}
  [data-line][data-inview]{animation:tl-slide-up 0.95s cubic-bezier(.16,1,.3,1) both}
  [data-line="1"][data-inview]{animation-delay:0.08s}
  [data-line="2"][data-inview]{animation-delay:0.16s}
  [data-line="3"][data-inview]{animation-delay:0.24s}
}
@media (prefers-reduced-motion: reduce){
  [data-reveal],[data-drift],[data-mask],[data-line],[data-rule],[data-late],[data-pull]{
    animation:none !important; opacity:1 !important; clip-path:none !important;
  }
  [data-reveal],[data-drift],[data-mask],[data-line],[data-rule],[data-pull]{transform:none !important}
}

/* hover underline sweep */
[data-sweep]{position:relative;}
[data-sweep]::after{content:""; position:absolute; left:0; right:0; bottom:-3px; height:1px; background:currentColor; transform:scaleX(0); transform-origin:right center; transition:transform 0.45s cubic-bezier(.16,1,.3,1);}
[data-sweep]:hover::after{transform:scaleX(1); transform-origin:left center;}

input, textarea{font-family:inherit;}

/* image-slot replacement: img fills its relative container, cover-cropped */
.tl-img{position:absolute; inset:0; width:100%; height:100%; object-fit:cover;}
.tl-frame{position:relative; overflow:hidden; min-width:0;}

/* generic hover helpers (JS applies via class, but keep CSS for buttons) */
.tl-btn-dark:hover{background:var(--ink); color:var(--paper);}
.tl-btn-line:hover{border-color:var(--ink);}
.tl-cta:hover{background:var(--clay) !important;}

/* whyUs reason cards hover */
.tl-reason{transition:background .5s cubic-bezier(.16,1,.3,1), border-color .5s cubic-bezier(.16,1,.3,1), color .5s ease, transform .5s cubic-bezier(.16,1,.3,1), box-shadow .5s cubic-bezier(.16,1,.3,1);}
.tl-reason:hover{background:#191715; border-color:#191715; color:#edeae3; transform:translateY(-6px); box-shadow:0 18px 44px rgba(31,29,26,0.16);}
.tl-reason:hover .tl-reason-no{color:#a8785f;}

/* work photo zoom */
.tl-zoom{transition:transform .9s cubic-bezier(.16,1,.3,1);}
.tl-zoom-wrap:hover .tl-zoom{transform:scale(1.05);}
.tl-zoom-wrap:hover .tl-zoom.tl-zoom-sm{transform:scale(1.03);}

/* nav overlay */
.tl-navlink{color:#edeae3; cursor:pointer; display:grid; grid-template-columns:26px 1fr auto; align-items:baseline; gap:16px; padding:11px 0; border-bottom:1px solid #2b2724; transition:color .3s ease;}
.tl-navlink:hover{color:#e0a98d;}

/* generic content (page.php / index.php) */
.tl-content{max-width:820px; margin:0 auto; padding:70px 32px 90px;}
.tl-content h1,.tl-content h2,.tl-content h3{font-family:'Noto Serif TC',serif;}
.tl-content h1{font-size:clamp(30px,4vw,52px); line-height:1.2; margin:0 0 24px;}
.tl-content p{font-size:15.5px; line-height:2; color:var(--body);}
.tl-content a{border-bottom:1px solid var(--line2);}
.tl-content img{height:auto; margin:24px 0;}

/* empty image-slot placeholder (mockup's intentional "cover pending" slots:
   film covers, decorative light signage, etc.) */
.tl-slot-ph{
  display:flex; align-items:center; justify-content:center; text-align:center;
  padding:16px; background:#e4e0d7; color:#8a8377;
  font-family:'Noto Serif TC',serif; font-weight:300;
  font-size:13px; letter-spacing:0.08em; line-height:1.6;
}
.tl-slot-ph span{max-width:16em;}
/* dark sections invert the placeholder tone */
[style*="#191715"] .tl-slot-ph{background:#221f1c; color:#7d746a;}

/* dynamic post / portfolio body typography (single*.php) */
.tl-entry{color:#3d3830;}
.tl-entry > *:first-child{margin-top:0;}
.tl-entry p{font-size:15px; line-height:2.1; color:var(--body); margin:0 0 18px;}
.tl-entry h1,.tl-entry h2,.tl-entry h3,.tl-entry h4{font-family:'Noto Serif TC',serif; line-height:1.4; margin:34px 0 14px;}
.tl-entry h2{font-size:clamp(20px,2.2vw,26px);}
.tl-entry h3{font-size:19px;}
.tl-entry img{height:auto; margin:22px 0;}
.tl-entry a{border-bottom:1px solid var(--line2);}
.tl-entry ul,.tl-entry ol{padding-left:1.2em; line-height:2; color:var(--body);}
.tl-entry blockquote{border-left:2px solid var(--clay); padding-left:22px; margin:28px 0; font-family:'Instrument Serif',serif; font-style:italic; font-size:22px; line-height:1.5;}
.tl-lang-mobile{display:none;}

/* reservation: two paths, one visual language */
.tl-reserve-tabs{
  display:grid; grid-template-columns:repeat(2,minmax(0,1fr));
  margin:48px 0 34px; border-top:1px solid #1f1d1a; border-bottom:1px solid #d6d1c5;
}
.tl-reserve-tab{
  appearance:none; border:0; border-right:1px solid #d6d1c5; border-radius:0;
  background:transparent; color:#8a8377; cursor:pointer; text-align:left;
  padding:18px 22px 17px; min-height:78px; transition:background .25s ease,color .25s ease;
}
.tl-reserve-tab:last-child{border-right:0;}
.tl-reserve-tab span{display:block; font-family:'Noto Serif TC',serif; font-size:17px; color:inherit;}
.tl-reserve-tab small{display:block; margin-top:6px; font-size:9.5px; letter-spacing:.2em; text-transform:uppercase; color:inherit;}
.tl-reserve-tab:hover,.tl-reserve-tab.is-active{background:#1f1d1a; color:#edeae3;}
.tl-reserve-tab:focus-visible,.tl-service-option:focus-visible,.tl-meeting-button:focus-visible{outline:2px solid #a8785f; outline-offset:3px;}
.tl-reserve-panel[hidden]{display:none !important;}
.tl-service-options{display:flex; gap:9px; flex-wrap:wrap;}
.tl-service-option{
  appearance:none; border:1px solid #c9c3b5; border-radius:0; background:transparent;
  color:#57524a; cursor:pointer; font:inherit; font-size:13px; padding:10px 18px;
  transition:background .2s ease,border-color .2s ease,color .2s ease,transform .2s ease;
}
.tl-service-option:hover{border-color:#1f1d1a; color:#1f1d1a;}
.tl-service-option.is-selected{background:#1f1d1a; border-color:#1f1d1a; color:#edeae3; transform:translateY(-1px);}
.tl-service-option.is-selected::before{content:'✓'; margin-right:7px; color:#e0a98d;}
.tl-meeting-layout{display:grid; grid-template-columns:minmax(0,1.05fr) minmax(0,.95fr); min-height:520px; border-bottom:1px solid #d6d1c5;}
.tl-meeting-intro{position:relative; overflow:hidden; background:#191715; color:#edeae3; padding:clamp(38px,6vw,82px);}
.tl-meeting-kicker{font-size:10px; letter-spacing:.24em; text-transform:uppercase; color:#a8785f;}
.tl-meeting-script{position:absolute; right:-18px; top:20px; font-family:'Instrument Serif',serif; font-style:italic; font-size:clamp(110px,17vw,250px); line-height:.8; color:rgba(237,234,227,.045); pointer-events:none;}
.tl-meeting-intro h2{position:relative; margin:70px 0 20px; max-width:8em; font-family:'Noto Serif TC',serif; font-size:clamp(30px,4vw,52px); font-weight:400; line-height:1.35;}
.tl-meeting-intro p{position:relative; max-width:31em; margin:0; font-size:14px; line-height:2; color:#a9a096;}
.tl-meeting-meta{position:relative; display:grid; grid-template-columns:1fr 1fr; gap:22px; margin-top:58px; padding-top:20px; border-top:1px solid #38322c;}
.tl-meeting-meta span{display:block; margin-bottom:8px; font-size:9.5px; letter-spacing:.18em; color:#7d746a;}
.tl-meeting-meta strong{font-family:'Noto Serif TC',serif; font-size:14px; font-weight:400; color:#edeae3;}
.tl-meeting-action{display:flex; flex-direction:column; justify-content:flex-start; align-items:stretch; padding:clamp(38px,5vw,68px); background:#f4f1ea;}
.tl-meeting-step{font-size:10px; letter-spacing:.22em; text-transform:uppercase; color:#a8785f;}
.tl-meeting-action h3{margin:25px 0 14px; max-width:9em; font-family:'Noto Serif TC',serif; font-size:clamp(25px,3vw,38px); font-weight:400; line-height:1.45; color:#1f1d1a;}
.tl-meeting-action p{max-width:27em; margin:0; font-size:14px; line-height:2; color:#57524a;}
.tl-meeting-button{display:flex; justify-content:space-between; align-items:center; gap:28px; width:100%; box-sizing:border-box; margin-top:24px; padding:18px 20px; border:1px solid #1f1d1a; border-radius:0; background:transparent; color:#1f1d1a; font:inherit; font-size:11px; letter-spacing:.18em; cursor:pointer; transition:background .25s ease,color .25s ease,opacity .2s ease;}
.tl-meeting-button:hover{background:#1f1d1a; color:#edeae3;}
.tl-meeting-button:disabled{cursor:wait; opacity:.5;}
.tl-meeting-note{margin-top:13px; font-size:11px; line-height:1.8; color:#8a8377;}
.tl-booking-dates{display:grid; grid-template-columns:repeat(7,minmax(0,1fr)); gap:7px; width:100%; margin-top:30px; padding-bottom:10px;}
.tl-booking-date{appearance:none; min-width:0; border:1px solid #d6d1c5; border-radius:0; background:#edeae3; color:#57524a; padding:10px 7px 11px; cursor:pointer; text-align:left; transition:background .2s,border-color .2s,color .2s;}
.tl-booking-date small{display:block; margin-bottom:5px; font-size:9px; letter-spacing:.12em; color:#8a8377;}
.tl-booking-date strong{display:block; font-family:'Instrument Serif',serif; font-size:22px; font-weight:400; line-height:1;}
.tl-booking-date:hover,.tl-booking-date.is-selected{border-color:#1f1d1a; background:#1f1d1a; color:#edeae3;}
.tl-booking-date.is-selected small{color:#caa477;}
.tl-booking-times{width:100%; margin-top:24px; padding-top:18px; border-top:1px solid #d6d1c5;}
.tl-booking-label{margin-bottom:12px; font-size:9.5px; letter-spacing:.18em; color:#8a8377;}
.tl-booking-slot-grid{display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:7px;}
.tl-booking-slot{appearance:none; min-height:42px; border:1px solid #c9c3b5; border-radius:0; background:transparent; color:#1f1d1a; font:inherit; font-size:13px; cursor:pointer; transition:background .2s,border-color .2s,color .2s;}
.tl-booking-slot:hover,.tl-booking-slot.is-selected{border-color:#a8785f; background:#a8785f; color:#fff;}
.tl-booking-slot:disabled{border-color:#ddd8cf; background:rgba(214,209,197,.28); color:#bbb4aa; text-decoration:line-through; cursor:not-allowed;}
.tl-booking-status{min-height:18px; margin-top:10px; font-size:11px; line-height:1.7; color:#a8785f;}
.tl-booking-form{display:grid; gap:18px; width:100%; margin-top:28px; padding-top:24px; border-top:1px solid #1f1d1a;}
.tl-booking-summary{font-family:'Noto Serif TC',serif; font-size:16px; line-height:1.7; color:#1f1d1a;}
.tl-booking-field-grid{display:grid; grid-template-columns:1fr 1fr; gap:18px;}
.tl-booking-form label{display:grid; gap:7px;}
.tl-booking-form label>span{font-size:9.5px; letter-spacing:.16em; color:#8a8377;}
.tl-booking-form input,.tl-booking-form textarea{width:100%; box-sizing:border-box; border:0; border-bottom:1px solid #c9c3b5; border-radius:0; background:transparent; color:#1f1d1a; padding:10px 0; font:inherit; font-size:14px; outline:none; resize:vertical;}
.tl-booking-form input:focus,.tl-booking-form textarea:focus{border-bottom-color:#1f1d1a;}
.tl-booking-hp{position:absolute !important; left:-9999px !important; width:1px !important; height:1px !important; overflow:hidden !important;}
.tl-booking-success{width:100%; margin:auto 0; padding:24px 0;}
.tl-booking-success-mark{display:grid; place-items:center; width:52px; height:52px; margin-bottom:24px; border:1px solid #a8785f; border-radius:50%; color:#a8785f; font-size:20px;}
.tl-booking-success h3{max-width:none; margin-top:15px;}

/* responsive: collapse 12-col grids on small screens */
@media (max-width:860px){
  .tl-grid12 > *{grid-column:1/-1 !important;}
  .tl-grid-hero{grid-template-columns:minmax(0,1fr) !important;}
  .tl-grid-hero #tl-hero{grid-column:1/-1; width:100%;}
  .tl-hero-mini-right{width:76px !important; right:10px !important; top:2px !important;}
  .tl-hero-mini-left{width:112px !important; left:10px !important; bottom:-34px !important;}
  .tl-hide-sm{display:none !important;}
  .tl-lang-mobile{display:flex !important;}
  .tl-stats{grid-template-columns:repeat(2,1fr) !important;}
  .tl-footer-cols > *{grid-column:1/-1 !important;}
  .tl-footcols{grid-template-columns:1fr 1fr !important;}
  /* design-part grids are inline-styled (no tl-grid12 class) — collapse them
     via attribute selector and neutralise their column spans */
  .tl-design [style*="grid-template-columns:repeat(12"],
  .tl-design [style*="grid-template-columns:repeat(3"],
  .tl-design [style*="grid-template-columns:repeat(4"]{
    grid-template-columns:1fr !important;
  }
  .tl-design [style*="grid-template-columns:repeat(12"] > *,
  .tl-design [style*="grid-template-columns:repeat(3"] > *,
  .tl-design [style*="grid-template-columns:repeat(4"] > *{
    grid-column:1/-1 !important;
  }
  .tl-design [style*="writing-mode:vertical"]{display:none !important;}
  .tl-design [style*="columns:3"]{columns:1 !important;}
  .tl-reserve-tabs{margin-top:36px;}
  .tl-reserve-tab{padding:15px 14px; min-height:70px;}
  .tl-reserve-tab span{font-size:15px;}
  .tl-reserve-tab small{font-size:8px; letter-spacing:.12em;}
  .tl-meeting-layout{grid-template-columns:1fr; min-height:0;}
  .tl-meeting-intro,.tl-meeting-action{padding:38px 24px;}
  .tl-meeting-intro h2{margin-top:46px;}
  .tl-meeting-meta{margin-top:40px;}
  .tl-booking-dates{gap:5px;}
  .tl-booking-date{padding:9px 4px 10px;}
  .tl-booking-date small{font-size:7.5px; letter-spacing:.04em;}
  .tl-booking-date strong{font-size:17px;}
  .tl-booking-slot-grid{grid-template-columns:repeat(3,minmax(0,1fr));}
  .tl-booking-field-grid{grid-template-columns:1fr;}
}
